1
0
mirror of https://github.com/postgres/postgres.git synced 2025-06-16 06:01:02 +03:00

Code review for b6fb6471f6.

Reports by Tomas Vondra, Vinayak Pokale, and Aleksander Alekseev.
Patch by Amit Langote.
This commit is contained in:
Robert Haas
2016-03-10 06:07:57 -05:00
parent cc402116ca
commit 090b287fc5
2 changed files with 5 additions and 4 deletions

View File

@ -2861,8 +2861,8 @@ pgstat_report_activity(BackendState state, const char *cmd_str)
/*----------- /*-----------
* pgstat_progress_start_command() - * pgstat_progress_start_command() -
* *
* Set st_command in own backend entry. Also, zero-initialize * Set st_progress_command (and st_progress_command_target) in own backend
* st_progress_param array. * entry. Also, zero-initialize st_progress_param array.
*----------- *-----------
*/ */
void void
@ -2904,7 +2904,8 @@ pgstat_progress_update_param(int index, int64 val)
/*----------- /*-----------
* pgstat_progress_end_command() - * pgstat_progress_end_command() -
* *
* Update index'th member in st_progress_param[] of own backend entry. * Reset st_progress_command (and st_progress_command_target) in own backend
* entry. This signals the end of the command.
*----------- *-----------
*/ */
void void

View File

@ -614,7 +614,7 @@ pg_stat_get_progress_info(PG_FUNCTION_ARGS)
else else
{ {
nulls[2] = true; nulls[2] = true;
for (i = 1; i < PGSTAT_NUM_PROGRESS_PARAM + 1; i++) for (i = 0; i < PGSTAT_NUM_PROGRESS_PARAM; i++)
nulls[i+3] = true; nulls[i+3] = true;
} }