X-Git-Url: https://git.gag.com/?p=debian%2Famanda;a=blobdiff_plain;f=gnulib%2Fsafe-read.c;h=855be677aa07f01dcb77f3907e6aa200f3529fce;hp=0cb1edee8bc789ab6589d2cd93c7e265ce1a418a;hb=b116e9366c7b2ea2c2eb53b0a13df4090e176235;hpb=fd48f3e498442f0cbff5f3606c7c403d0566150e diff --git a/gnulib/safe-read.c b/gnulib/safe-read.c index 0cb1ede..855be67 100644 --- a/gnulib/safe-read.c +++ b/gnulib/safe-read.c @@ -1,7 +1,7 @@ /* An interface to read and write that retries after interrupts. - Copyright (C) 1993, 1994, 1998, 2002, 2003, 2004, 2005, 2006 Free - Software Foundation, Inc. + Copyright (C) 1993-1994, 1998, 2002-2006, 2009-2010 Free Software + Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -66,12 +66,12 @@ safe_rw (int fd, void const *buf, size_t count) ssize_t result = rw (fd, buf, count); if (0 <= result) - return result; + return result; else if (IS_EINTR (errno)) - continue; + continue; else if (errno == EINVAL && BUGGY_READ_MAXIMUM < count) - count = BUGGY_READ_MAXIMUM; + count = BUGGY_READ_MAXIMUM; else - return result; + return result; } }