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)
2490
2490
volatile PgBackendStatus * beentry = MyBEEntry ;
2491
2491
TimestampTz start_timestamp ;
2492
2492
TimestampTz current_timestamp ;
2493
- int len ;
2493
+ int len = 0 ;
2494
2494
2495
2495
TRACE_POSTGRESQL_STATEMENT_STATUS (cmd_str );
2496
2496
@@ -2524,8 +2524,8 @@ pgstat_report_activity(BackendState state, const char *cmd_str)
2524
2524
start_timestamp = GetCurrentStatementStartTimestamp ();
2525
2525
if (cmd_str != NULL )
2526
2526
{
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 );
2529
2529
}
2530
2530
2531
2531
/*
You can’t perform that action at this time.
0 commit comments