Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 8bc5555

Browse files
kvapkelvich
authored andcommitted
Move 'status' variable declaration to the top of the block.
1 parent 5dec7f6 commit 8bc5555

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

pglogical_receiver.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,6 +246,7 @@ pglogical_receiver_main(Datum main_arg)
246246
while (!got_sigterm)
247247
{
248248
int count;
249+
ConnStatusType status;
249250

250251
/*
251252
* Determine when and how we should open replication slot.
@@ -261,7 +262,7 @@ pglogical_receiver_main(Datum main_arg)
261262

262263
/* Establish connection to remote server */
263264
conn = PQconnectdb(connString);
264-
ConnStatusType status = PQstatus(conn);
265+
status = PQstatus(conn);
265266
if (status != CONNECTION_OK)
266267
{
267268
ereport(WARNING, (errmsg("%s: Could not establish connection to remote server (%s), status = %d, error = %s",

0 commit comments

Comments
 (0)