Skip to content

Commit 133432e

Browse files
danolivoartemgavrilov
authored andcommitted
Fix annoying compilation warnings
1 parent bcd345a commit 133432e

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

pg_stat_monitor.c

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,6 @@ void _PG_init(void);
8282

8383
/* Current nesting depth of planner/ExecutorRun/ProcessUtility calls */
8484
static int nesting_level = 0;
85-
volatile bool __pgsm_do_not_capture_error = false;
8685

8786
#if PG_VERSION_NUM < 170000
8887
/* Before planner nesting level was conunted separately */
@@ -98,10 +97,10 @@ static int hist_bucket_count_total;
9897

9998
static uint32 pgsm_client_ip = PGSM_INVALID_IP_MASK;
10099

101-
/* The array to store outer layer query id*/
102-
int64 *nested_queryids;
103-
char **nested_query_txts;
104-
List *lentries = NIL;
100+
/* The array to store outer layer query id */
101+
static int64 *nested_queryids;
102+
static char **nested_query_txts;
103+
static List *lentries = NIL;
105104

106105
static char relations[REL_LST][REL_LEN];
107106

@@ -211,12 +210,12 @@ static void pgsm_cleanup_callback(void *arg);
211210
static void pgsm_store_error(const char *query, ErrorData *edata);
212211

213212
/*---- Local variables ----*/
214-
MemoryContextCallback mem_cxt_reset_callback =
213+
static MemoryContextCallback mem_cxt_reset_callback =
215214
{
216215
.func = pgsm_cleanup_callback,
217216
.arg = NULL
218217
};
219-
volatile bool callback_setup = false;
218+
static volatile bool callback_setup = false;
220219

221220
static void pgsm_update_entry(pgsmEntry *entry,
222221
const char *query,

0 commit comments

Comments
 (0)