From 6581e8bbef00ee093fec63c59cb87c913615340a Mon Sep 17 00:00:00 2001 From: Jovi Zhang Date: Tue, 29 Nov 2011 05:23:56 +0800 Subject: erts: minor fix for unnecessary condition In "while (retval != -1 && retval == SENDFILE_CHUNK_SIZE)", "retval != -1" is pointless. --- erts/emulator/drivers/unix/unix_efile.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erts/emulator/drivers/unix/unix_efile.c b/erts/emulator/drivers/unix/unix_efile.c index 72911641d3..e005690d78 100644 --- a/erts/emulator/drivers/unix/unix_efile.c +++ b/erts/emulator/drivers/unix/unix_efile.c @@ -1500,7 +1500,7 @@ efile_sendfile(Efile_error* errInfo, int in_fd, int out_fd, written += retval; *nbytes -= retval; } - } while (retval != -1 && retval == SENDFILE_CHUNK_SIZE); + } while (retval == SENDFILE_CHUNK_SIZE); *nbytes = written; return check_error(retval == -1 ? -1 : 0, errInfo); #elif defined(DARWIN) -- cgit v1.2.3