mirror of
https://github.com/postgres/postgres.git
synced 2025-09-09 13:09:39 +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:
@@ -135,11 +135,11 @@ pg_GSS_write(PGconn *conn, const void *ptr, size_t len)
|
||||
*/
|
||||
if (PqGSSSendLength)
|
||||
{
|
||||
ssize_t ret;
|
||||
ssize_t retval;
|
||||
ssize_t amount = PqGSSSendLength - PqGSSSendNext;
|
||||
|
||||
ret = pqsecure_raw_write(conn, PqGSSSendBuffer + PqGSSSendNext, amount);
|
||||
if (ret <= 0)
|
||||
retval = pqsecure_raw_write(conn, PqGSSSendBuffer + PqGSSSendNext, amount);
|
||||
if (retval <= 0)
|
||||
{
|
||||
/*
|
||||
* Report any previously-sent data; if there was none, reflect
|
||||
@@ -149,16 +149,16 @@ pg_GSS_write(PGconn *conn, const void *ptr, size_t len)
|
||||
*/
|
||||
if (bytes_sent)
|
||||
return bytes_sent;
|
||||
return ret;
|
||||
return retval;
|
||||
}
|
||||
|
||||
/*
|
||||
* Check if this was a partial write, and if so, move forward that
|
||||
* far in our buffer and try again.
|
||||
*/
|
||||
if (ret != amount)
|
||||
if (retval != amount)
|
||||
{
|
||||
PqGSSSendNext += ret;
|
||||
PqGSSSendNext += retval;
|
||||
continue;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user