X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Flanguage%2Futilities%2Foutput.c;h=f0dd016a829bfb2daa7e4c1049453d8c4964a622;hb=2cf2acba57a529b219d4251acfc36642e0a19fb3;hp=a699fdf5f5e4ef9968f14bdb24c4bf180bd4ada9;hpb=5cab4cf3322f29c0ed7134d23740e07382914f20;p=pspp diff --git a/src/language/utilities/output.c b/src/language/utilities/output.c index a699fdf5f5..f0dd016a82 100644 --- a/src/language/utilities/output.c +++ b/src/language/utilities/output.c @@ -61,7 +61,7 @@ cmd_output (struct lexer *lexer, struct dataset *ds UNUSED) else if (lex_match_id (lexer, "TABLECELLS")) { string_set_clear (&rc_names); - struct fmt_spec fmt = { 0, 0, 0 }; + struct fmt_spec fmt = { .type = 0 }; while (lex_token (lexer) != T_SLASH && lex_token (lexer) != T_ENDCMD) @@ -86,8 +86,8 @@ cmd_output (struct lexer *lexer, struct dataset *ds UNUSED) else if (lex_match_id (lexer, "FORMAT")) { char type[FMT_TYPE_LEN_MAX + 1]; - int width = -1; - int decimals = -1; + uint16_t width; + uint8_t decimals; if (! lex_force_match (lexer, T_EQUALS)) goto error; @@ -135,6 +135,7 @@ cmd_output (struct lexer *lexer, struct dataset *ds UNUSED) } } + string_set_destroy (&rc_names); return CMD_SUCCESS; error: