summaryrefslogtreecommitdiff
path: root/contrib/postgres_fdw/connection.c
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/postgres_fdw/connection.c')
-rw-r--r--contrib/postgres_fdw/connection.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/contrib/postgres_fdw/connection.c b/contrib/postgres_fdw/connection.c
index cffb6f83107..939d114f02e 100644
--- a/contrib/postgres_fdw/connection.c
+++ b/contrib/postgres_fdw/connection.c
@@ -1678,8 +1678,8 @@ postgres_fdw_get_connections(PG_FUNCTION_ARGS)
while ((entry = (ConnCacheEntry *) hash_seq_search(&scan)))
{
ForeignServer *server;
- Datum values[POSTGRES_FDW_GET_CONNECTIONS_COLS];
- bool nulls[POSTGRES_FDW_GET_CONNECTIONS_COLS];
+ Datum values[POSTGRES_FDW_GET_CONNECTIONS_COLS] = {0};
+ bool nulls[POSTGRES_FDW_GET_CONNECTIONS_COLS] = {0};
/* We only look for open remote connections */
if (!entry->conn)
@@ -1687,9 +1687,6 @@ postgres_fdw_get_connections(PG_FUNCTION_ARGS)
server = GetForeignServerExtended(entry->serverid, FSV_MISSING_OK);
- MemSet(values, 0, sizeof(values));
- MemSet(nulls, 0, sizeof(nulls));
-
/*
* The foreign server may have been dropped in current explicit
* transaction. It is not possible to drop the server from another