~ubuntu-branches/ubuntu/vivid/bc/vivid-proposed

« back to all changes in this revision

Viewing changes to bc/storage.c

  • Committer: Bazaar Package Importer
  • Author(s): Matthias Klose
  • Date: 2007-12-05 12:24:03 UTC
  • mfrom: (3.1.2 lenny)
  • Revision ID: james.westby@ubuntu.com-20071205122403-rv1a7x90ktu1wl95
Tags: 1.06.94-3ubuntu1
* Merge with Debian; remaining changes:
  - Make bc/dc notice read and write errors on its input and output.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* storage.c:  Code and data storage manipulations.  This includes labels. */
2
 
 
3
1
/*  This file is part of GNU bc.
4
 
    Copyright (C) 1991-1994, 1997, 2000 Free Software Foundation, Inc.
 
2
 
 
3
    Copyright (C) 1991-1994, 1997, 2006 Free Software Foundation, Inc.
5
4
 
6
5
    This program is free software; you can redistribute it and/or modify
7
6
    it under the terms of the GNU General Public License as published by
14
13
    GNU General Public License for more details.
15
14
 
16
15
    You should have received a copy of the GNU General Public License
17
 
    along with this program; see the file COPYING.  If not, write to
 
16
    along with this program; see the file COPYING.  If not, write to:
18
17
      The Free Software Foundation, Inc.
19
 
      59 Temple Place, Suite 330
20
 
      Boston, MA 02111 USA
 
18
      Foundation, Inc.  51 Franklin Street, Fifth Floor,
 
19
      Boston, MA 02110-1301  USA
21
20
 
22
21
    You may contact the author by:
23
22
       e-mail:  philnelson@acm.org
28
27
       
29
28
*************************************************************************/
30
29
 
 
30
/* storage.c:  Code and data storage manipulations.  This includes labels. */
 
31
 
31
32
#include "bcdefs.h"
32
 
#include "global.h"
33
33
#include "proto.h"
34
34
 
35
35
 
135
135
 
136
136
  /* Copy the old variables. */
137
137
  for (indx = 3; indx < old_count; indx++)
138
 
    variables[indx] = old_var[indx];
 
138
    {
 
139
      variables[indx] = old_var[indx];
 
140
      v_names[indx] = old_names[indx];
 
141
    }
139
142
 
140
143
  /* Initialize the new elements. */
141
144
  for (; indx < v_count; indx++)
169
172
 
170
173
  /* Copy the old arrays. */
171
174
  for (indx = 1; indx < old_count; indx++)
172
 
    arrays[indx] = old_ary[indx];
 
175
    {
 
176
      arrays[indx] = old_ary[indx];
 
177
      a_names[indx] = old_names[indx];
 
178
    }
173
179
 
174
180
 
175
181
  /* Initialize the new elements. */