From 52418a9a79b8f4913e13a75d921d4251eeaf1c5e Mon Sep 17 00:00:00 2001 From: Dave Cramer Date: Tue, 5 Nov 2019 07:14:30 -0500 Subject: [PATCH 5/8] Remove C99 declaration and code --- src/backend/replication/logical/proto.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/backend/replication/logical/proto.c b/src/backend/replication/logical/proto.c index 6494b645d0..d4c6283a17 100644 --- a/src/backend/replication/logical/proto.c +++ b/src/backend/replication/logical/proto.c @@ -547,10 +547,11 @@ logicalrep_read_tuple(StringInfo in, LogicalRepTupleData *tuple) break; case 'b': /* binary formatted value */ { + int len; tuple->changed[i] = true; tuple->binary[i] = true; - int len = pq_getmsgint(in, 4); /* read length */ + len = pq_getmsgint(in, 4); /* read length */ tuple->values[i].data = palloc(len + 1); /* and data */ @@ -565,8 +566,9 @@ logicalrep_read_tuple(StringInfo in, LogicalRepTupleData *tuple) } case 't': /* text formatted value */ { + int len; tuple->changed[i] = true; - int len = pq_getmsgint(in, 4); /* read length */ + len = pq_getmsgint(in, 4); /* read length */ /* and data */ tuple->values[i].data = palloc(len + 1); -- 2.20.1 (Apple Git-117)