File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -2490,7 +2490,7 @@ pgstat_report_activity(BackendState state, const char *cmd_str)
24902490 volatile PgBackendStatus * beentry = MyBEEntry ;
24912491 TimestampTz start_timestamp ;
24922492 TimestampTz current_timestamp ;
2493- int len ;
2493+ int len = 0 ;
24942494
24952495 TRACE_POSTGRESQL_STATEMENT_STATUS (cmd_str );
24962496
@@ -2524,8 +2524,8 @@ pgstat_report_activity(BackendState state, const char *cmd_str)
25242524 start_timestamp = GetCurrentStatementStartTimestamp ();
25252525 if (cmd_str != NULL )
25262526 {
2527- len = strlen (cmd_str );
2528- len = pg_mbcliplen ( cmd_str , len , pgstat_track_activity_query_size - 1 );
2527+ len = pg_mbcliplen ( cmd_str , strlen (cmd_str ),
2528+ pgstat_track_activity_query_size - 1 );
25292529 }
25302530
25312531 /*
You can’t perform that action at this time.
0 commit comments