diff --git a/src/bin/psql/command.c b/src/bin/psql/command.c index 645ba5b..d36e5de 100644 --- a/src/bin/psql/command.c +++ b/src/bin/psql/command.c @@ -71,6 +71,7 @@ static void printSSLInfo(void); static void checkWin32Codepage(void); #endif + /* * Possible states for simple state machine, that is used for * parsing target list - list of varnames separated by comma. @@ -760,7 +761,7 @@ exec_command(const char *cmd, /* \gset send query and store result */ else if (strcmp(cmd, "gset") == 0) { - char *packet; + char *packet; VarlistParserState state = VARLIST_INITIAL; /* expected valid target list */ @@ -768,32 +769,31 @@ exec_command(const char *cmd, pset.gvars = NULL; /* - * So we would to enable subtitution, but we know so target varname should - * not use comma. Recheck of variable name is done by variable setting routine. - * psql_scan_slash_option can returns zero or more identifiers separated by - * comma. We cennot to use OT_WHOLE_LINE, because variable substitution is not - * supported there. + * So we would to enable substitution, but we know so target varname + * should not use comma. Recheck of variable name is done by variable + * setting routine. psql_scan_slash_option can returns zero or more + * identifiers separated by comma. We cannot to use OT_WHOLE_LINE, + * because variable substitution is not supported there. */ while ((packet = psql_scan_slash_option(scan_state, - OT_NORMAL, NULL, false))) + OT_NORMAL, NULL, false))) { - char *token = packet; - bool process_comma = false; + char *token = packet; + bool process_comma = false; while (success && (*token || process_comma)) { if (process_comma) { if (state == VARLIST_INITIAL || - state == VARLIST_EXPECTED_COMMA_OR_IDENT) + state == VARLIST_EXPECTED_COMMA_OR_IDENT) pset.gvars = tglist_add(pset.gvars, NULL); state = VARLIST_EXPECTED_COMMA_OR_IDENT; - process_comma = false; } else { - char *ptr = token; + char *ptr = token; /* skip initial blank chars */ while (*ptr && isblank(*ptr)) @@ -816,7 +816,7 @@ exec_command(const char *cmd, if (token != ptr) { if (state == VARLIST_INITIAL || - state == VARLIST_EXPECTED_COMMA_OR_IDENT) + state == VARLIST_EXPECTED_COMMA_OR_IDENT) { pset.gvars = tglist_add(pset.gvars, token); state = VARLIST_EXPECTED_COMMA;