This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
pread, pwrite linux implementation does not conform to Single UnixSpecification
- From: "Gerhard Tonn" <TON at de dot ibm dot com>
- To: libc-alpha at sources dot redhat dot com
- Date: Wed, 10 Jul 2002 12:59:59 +0200
- Subject: pread, pwrite linux implementation does not conform to Single UnixSpecification
- Sensitivity:
Hi,
we have recently experienced problems with the ltp (linux test project)
testsuite, when passing a negative value as offset to pread and pwrite. The
functions don't return EINVAL as specified by
http://www.opengroup.org/onlinepubs/007908799/xsh/write.html and
http://www.opengroup.org/onlinepubs/007908799/xsh/read.html respectively,
but return EFBIG or no error at all. This problem appears on all platforms
using the sysdeps/unix/sysv/linux/ default implementation. The
implementation doesn't check for negative values and use the
__LONG_LONG_PAIR macro to convert from an off_t to a loff_t, which doesn't
do any sign extension. Could that be fixed?
Regards / Mit freundlichen Gruessen
Gerhard
Gerhard Tonn, Linux for eServer Development, +(49)-7031-16-4716, Lotus
Notes: ton@ibmde,
Internet: ton@de.ibm.com