projects
/
postgresql.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
325c54b
)
Return value of lseek() can be negative on failure.
author
Heikki Linnakangas
Mon, 14 Jan 2013 22:42:37 +0000
(
00:42
+0200)
committer
Heikki Linnakangas
Mon, 14 Jan 2013 22:42:37 +0000
(
00:42
+0200)
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
src/backend/replication/walsender.c
patch
|
blob
|
blame
|
history
diff --git
a/src/backend/replication/walsender.c
b/src/backend/replication/walsender.c
index 5408b142f8d9b7d0522327c9daafc36090ba4348..ad7d1c911b377d94bb21fc20a72521b2bb72d3ac 100644
(file)
--- a/
src/backend/replication/walsender.c
+++ b/
src/backend/replication/walsender.c
@@
-315,8
+315,8
@@
SendTimeLineHistory(TimeLineHistoryCmd *cmd)
char histfname[MAXFNAMELEN];
char path[MAXPGPATH];
int fd;
-
size_t
histfilelen;
-
size_t
bytesleft;
+
off_t
histfilelen;
+
off_t
bytesleft;
/*
* Reply with a result set with one row, and two columns. The first col