On Tue, Mar 01, 2016 at 02:00:56PM -0700, Martin Natano wrote: > CVSROOT: /cvs > Module name: src > Changes by: nat...@cvs.openbsd.org 2016/03/01 14:00:56 > > Modified files: > sys/ufs/ext2fs : ext2fs_readwrite.c > sys/ufs/ffs : ffs_vnops.c > > Log message: >
Well, this should have included a log message. Here it is: Tweak return values for ffs_read() and ext2fs_read(). Both functions returned EFBIG when the read offset was smaller than zero or larger than the maximum file size. According to posix the right thing to do is to return EINVAL for an offset smaller than zero and 0 for an offset past the EOF (i.e. a short read). discussion and ok stefan@