Incorrect preadv/pwritev argument parsing on ARM EABI

Dmitry V. Levin ldv at altlinux.org
Thu Apr 17 14:25:59 UTC 2014


On Thu, Apr 17, 2014 at 01:03:31PM +0400, Dmitry V. Levin wrote:
> On Wed, Apr 16, 2014 at 11:19:06PM -0700, Dima Kogan wrote:
> > Dima Kogan <dima at secretsauce.net> writes:
> > > Dmitry V. Levin <ldv at altlinux.org> writes:
> > >
> > >> Unfortunately, your patch breaks all 64-bit architectures because offset
> > >> is passed as a single argument
> > >
> > > Oh yeah. I clearly broke that; sorry about that. We want to parse preadv
> > > and pwritev in exactly the same way we parse llseek. That syscall does
> > > the same arg splitting. Its code looks very similar, so after 30 seconds
> > > of looking at it I'm not yet sure why that works. I'll look more closely
> > > later tonight.
> > 
> > OK. Never mind on the llseek, actually. I was testing lseek, NOT llseek,
> > which is why it looked odd. The patch I attached earlier can be fixed
> > with some #ifdefs probably. I should be pretty trivial. Is it useful for
> > me to do it, or do you want to?
> 
> If the result is going to be as complex as printllval without alignment,
> it worth extending printllval instead of reinventing the wheel.

I've pushed a fix:
http://sourceforge.net/p/strace/code/ci/7845a42b39e59e904d01e75e21f7bc7eb6462560/


-- 
ldv
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <http://lists.strace.io/pipermail/strace-devel/attachments/20140417/92e79ded/attachment.bin>


More information about the Strace-devel mailing list