projects
/
pspp
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fixed error running 'make distcheck'
[pspp]
/
src
/
language
/
data-io
/
list.c
diff --git
a/src/language/data-io/list.c
b/src/language/data-io/list.c
index 920d66e322b4009c518cbc5ef1a4fbc9eca5a501..2fc9baaf436e4f8cbdb3c958e245799c0d849ece 100644
(file)
--- a/
src/language/data-io/list.c
+++ b/
src/language/data-io/list.c
@@
-113,11
+113,12
@@
list_execute (const struct lst_cmd *lcmd, struct dataset *ds)
else
cases->hide_all_labels = true;
else
cases->hide_all_labels = true;
- casenumber case_num =
1
;
+ casenumber case_num =
lcmd->first
;
for (; (c = casereader_read (group)) != NULL; case_unref (c))
{
int case_idx = pivot_category_create_leaf (
for (; (c = casereader_read (group)) != NULL; case_unref (c))
{
int case_idx = pivot_category_create_leaf (
- cases->root, pivot_value_new_integer (case_num++));
+ cases->root, pivot_value_new_integer (case_num));
+ case_num += lcmd->step;
for (int i = 0; i < lcmd->n_variables; i++)
pivot_table_put2 (table, i, case_idx,
for (int i = 0; i < lcmd->n_variables; i++)
pivot_table_put2 (table, i, case_idx,
@@
-157,23
+158,23
@@
cmd_list (struct lexer *lexer, struct dataset *ds)
while (lex_token (lexer) != T_ENDCMD)
{
lex_match (lexer, T_SLASH);
while (lex_token (lexer) != T_ENDCMD)
{
lex_match (lexer, T_SLASH);
- if (lex_match_id (lexer, "VARIABLES")
)
+ if (lex_match_id (lexer, "VARIABLES"))
{
lex_match (lexer, T_EQUALS);
{
lex_match (lexer, T_EQUALS);
- if (! parse_variables_const (lexer, dict, &cmd.v_variables, &cmd.n_variables, 0
))
+ if (! parse_variables_const (lexer, dict, &cmd.v_variables, &cmd.n_variables, 0))
{
msg (SE, _("No variables specified."));
return CMD_FAILURE;
}
}
{
msg (SE, _("No variables specified."));
return CMD_FAILURE;
}
}
- else if (lex_match_id (lexer, "FORMAT")
)
+ else if (lex_match_id (lexer, "FORMAT"))
{
lex_match (lexer, T_EQUALS);
{
lex_match (lexer, T_EQUALS);
- if (lex_match_id (lexer, "NUMBERED")
)
+ if (lex_match_id (lexer, "NUMBERED"))
{
cmd.numbering = format_numbered;
}
{
cmd.numbering = format_numbered;
}
- else if (lex_match_id (lexer, "UNNUMBERED")
)
+ else if (lex_match_id (lexer, "UNNUMBERED"))
{
cmd.numbering = format_unnumbered;
}
{
cmd.numbering = format_unnumbered;
}
@@
-206,7
+207,7
@@
cmd_list (struct lexer *lexer, struct dataset *ds)
lex_get (lexer);
}
}
lex_get (lexer);
}
}
- else if (! parse_variables_const (lexer, dict, &cmd.v_variables, &cmd.n_variables, 0
))
+ else if (! parse_variables_const (lexer, dict, &cmd.v_variables, &cmd.n_variables, 0))
{
return CMD_FAILURE;
}
{
return CMD_FAILURE;
}