191 |
{ |
{ |
192 |
/* Add the weight variable to the end of the variable list. */ |
/* Add the weight variable to the end of the variable list. */ |
193 |
cmd.n_variables++; |
cmd.n_variables++; |
194 |
cmd.v_variables = xrealloc (cmd.v_variables, |
cmd.v_variables = xnrealloc (cmd.v_variables, cmd.n_variables, |
195 |
(cmd.n_variables |
sizeof *cmd.v_variables); |
|
* sizeof *cmd.v_variables)); |
|
196 |
cmd.v_variables[cmd.n_variables - 1] |
cmd.v_variables[cmd.n_variables - 1] |
197 |
= dict_get_weight (default_dict); |
= dict_get_weight (default_dict); |
198 |
} |
} |
214 |
|
|
215 |
/* Add the weight variable at the beginning of the variable list. */ |
/* Add the weight variable at the beginning of the variable list. */ |
216 |
cmd.n_variables++; |
cmd.n_variables++; |
217 |
cmd.v_variables = xrealloc (cmd.v_variables, |
cmd.v_variables = xnrealloc (cmd.v_variables, |
218 |
cmd.n_variables * sizeof *cmd.v_variables); |
cmd.n_variables, sizeof *cmd.v_variables); |
219 |
memmove (&cmd.v_variables[1], &cmd.v_variables[0], |
memmove (&cmd.v_variables[1], &cmd.v_variables[0], |
220 |
(cmd.n_variables - 1) * sizeof *cmd.v_variables); |
(cmd.n_variables - 1) * sizeof *cmd.v_variables); |
221 |
cmd.v_variables[0] = &casenum_var; |
cmd.v_variables[0] = &casenum_var; |
302 |
size_t x; |
size_t x; |
303 |
|
|
304 |
/* Allocate, initialize header. */ |
/* Allocate, initialize header. */ |
305 |
prc->header = xmalloc (sizeof (char *) * prc->header_rows); |
prc->header = xnmalloc (prc->header_rows, sizeof *prc->header); |
306 |
{ |
{ |
307 |
int w = n_chars_width (d); |
int w = n_chars_width (d); |
308 |
for (i = 0; i < prc->header_rows; i++) |
for (i = 0; i < prc->header_rows; i++) |