Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
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

+2-2
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)