author | Samuel Tardieu <sam@rfc1149.net> | |
Mon, 6 Oct 2008 17:28:41 +0000 (19:28 +0200) | ||
committer | Shawn O. Pearce <spearce@spearce.org> | |
Wed, 8 Oct 2008 14:38:48 +0000 (07:38 -0700) | ||
commit | fb7424363643d6049faf3bda399e5e602782b5b7 | |
tree | 3b0fae24a1fc6f2c534afec7d4803192667f2dca | tree | snapshot |
parent | 0a2c7eea41867ead2b2fb1d5898494c3a72405e5 | commit | diff |
Do not use errno when pread() returns 0
If we use pread() while at the end of the file, it will return 0, which is
not an error from the operating system point of view. In this case, errno
has not been set and must not be used.
Signed-off-by: Samuel Tardieu <sam@rfc1149.net>
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
If we use pread() while at the end of the file, it will return 0, which is
not an error from the operating system point of view. In this case, errno
has not been set and must not be used.
Signed-off-by: Samuel Tardieu <sam@rfc1149.net>
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
index-pack.c | diff | blob | history |