Date: Mon, 11 Jan 2010 15:19:39 +0300 From: Andrey Chernov <ache@nagual.pp.ru> To: Bruce Evans <brde@optusnet.com.au> Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org, Colin Percival <cperciva@FreeBSD.org> Subject: Re: svn commit: r201999 - head/lib/libc/stdio Message-ID: <20100111121938.GA57442@nagual.pp.ru> In-Reply-To: <20100111134429.F1302@besplex.bde.org> References: <201001101430.o0AEUURS051917@svn.freebsd.org> <20100110212548.GA47331@nagual.pp.ru> <4B4A5252.9070205@freebsd.org> <20100111134429.F1302@besplex.bde.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Jan 11, 2010 at 02:29:03PM +1100, Bruce Evans wrote: > >> 3) errno should be EOVERFLOW, see other owerflow checks in the stdio. > > There are none. I (we?) intentionally didn't set errno when the correct F.e. see fseek()/fseeko() stdio checks, as POSIX says: [EOVERFLOW] For fseek(), the resulting file offset would be a value which cannot be represented correctly in an object of type long. [EOVERFLOW] For fseeko(), the resulting file offset would be a value which cannot be represented correctly in an object of type off_t. Moreover, POSIX tends to introduce EOVERFLOW now in many places like old system calls too, see read()/pread(): [EOVERFLOW] The file is a regular file, nbyte is greater than 0, the starting position is before the end-of-file, and the starting position is greater than or equal to the offset maximum established in the open file description associated with fildes. (IEEE P1003.1 Draft 5.1 Issue 7 quoted in both cases) -- http://ache.pp.ru/
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20100111121938.GA57442>