/[pspp]/pspp/src/sfm-write.c
ViewVC logotype

Diff of /pspp/src/sfm-write.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.21 by blp, Tue Oct 25 04:28:17 2005 UTC revision 1.22 by blp, Wed Oct 26 05:06:14 2005 UTC
# Line 173  sfm_open_writer (struct file_handle *fh, Line 173  sfm_open_writer (struct file_handle *fh,
173    w->x = w->y = NULL;    w->x = w->y = NULL;
174    
175    w->var_cnt = dict_get_var_cnt (d);    w->var_cnt = dict_get_var_cnt (d);
176    w->vars = xmalloc (sizeof *w->vars * w->var_cnt);    w->vars = xnmalloc (w->var_cnt, sizeof *w->vars);
177    for (i = 0; i < w->var_cnt; i++)    for (i = 0; i < w->var_cnt; i++)
178      {      {
179        const struct variable *dv = dict_get_var (d, i);        const struct variable *dv = dict_get_var (d, i);
# Line 242  sfm_open_writer (struct file_handle *fh, Line 242  sfm_open_writer (struct file_handle *fh,
242    
243    if (w->compress)    if (w->compress)
244      {      {
245        w->buf = xmalloc (sizeof *w->buf * 128);        w->buf = xnmalloc (128, sizeof *w->buf);
246        w->ptr = w->buf;        w->ptr = w->buf;
247        w->end = &w->buf[128];        w->end = &w->buf[128];
248        w->x = (unsigned char *) w->ptr++;        w->x = (unsigned char *) w->ptr++;

Legend:
Removed from v.1.21  
changed lines
  Added in v.1.22

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26