Skip to content

Commit 3f4b174

Browse files
committed
Return value of lseek() can be negative on failure.
Because the return value of lseek() was assigned to an unsigned size_t variable, we'd fail to notice an error return code -1. Compiler gave a warning about this. Andres Freund
1 parent 325c54b commit 3f4b174

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/backend/replication/walsender.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -315,8 +315,8 @@ SendTimeLineHistory(TimeLineHistoryCmd *cmd)
315315
char histfname[MAXFNAMELEN];
316316
char path[MAXPGPATH];
317317
int fd;
318-
size_t histfilelen;
319-
size_t bytesleft;
318+
off_t histfilelen;
319+
off_t bytesleft;
320320

321321
/*
322322
* Reply with a result set with one row, and two columns. The first col

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy