1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-30 11:03:19 +03:00

Fix final warnings produced by -Wshadow=compatible-local

I thought I had these in d8df67bb1, but per report from Andres Freund, I
missed some.

Reviewed-by: Andres Freund
Discussion: https://postgr.es/m/20221005214052.c4tkudawyp5wxt3c@awork3.anarazel.de
This commit is contained in:
David Rowley
2022-10-07 13:13:27 +13:00
parent 4289263cf2
commit cd4e8caaa0
10 changed files with 32 additions and 43 deletions

View File

@ -128,15 +128,15 @@ typedef struct
/* finalize a newly-constructed hstore */
#define HS_FINALIZE(hsp_,count_,buf_,ptr_) \
do { \
int buflen = (ptr_) - (buf_); \
int _buflen = (ptr_) - (buf_); \
if ((count_)) \
ARRPTR(hsp_)[0].entry |= HENTRY_ISFIRST; \
if ((count_) != HS_COUNT((hsp_))) \
{ \
HS_SETCOUNT((hsp_),(count_)); \
memmove(STRPTR(hsp_), (buf_), buflen); \
memmove(STRPTR(hsp_), (buf_), _buflen); \
} \
SET_VARSIZE((hsp_), CALCDATASIZE((count_), buflen)); \
SET_VARSIZE((hsp_), CALCDATASIZE((count_), _buflen)); \
} while (0)
/* ensure the varlena size of an existing hstore is correct */