On 14/08/09 14:43, John Reiser wrote:
>> pread64(3, "\177ELF\1\2\1\0\0\0\0\0\0\0\0\0\0\2\0\24\0\0\0\1\20\0 "..., 
>> 4096, 0) = 4096
>> pread64(3, "\177ELF\1\2\1\0\0\0\0\0\0\0\0\0\0\2\0\24\0\0\0\1\20\0 "..., 
>> 4096, 0) = 4096
>
> --------------------------------------------------------------------------^^^^-------^^^^
>
> [versus]
>
>> pread64(3, "\177ELF\1\2\1\0\0\0\0\0\0\0\0\0\0\2\0\24\0\0\0\1\20\0 "..., 
>> 4096, 0) = 4096
>> pread64(3, "\335\335\335\335\335\335\335\335\335\335\335\335\335\335"..., 
>> 52, 0) = 52
>
> ----------------------------------------------------------------------------^^-------^^
>
>
>> Except for the geteuid(), stat64() and fstat64(), there seems to be no  
>> difference.
>
> The second call to pread64 has a third argument of 52 instead of 4096.

Which should be fine of course - it just means we're only asking for the 
first 52 bytes of the file instead of the first 4096 bytes. As far as I 
know there is no requirement for the size or offset given to pread to be 
page aligned or anything like that so both should work.

It might of course explain why the test program is not showing the problem.

I still reckon this is a kernel bug, although it may well be the change 
in the count that triggers it.

Tom

-- 
Tom Hughes ([email protected])
http://www.compton.nu/

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Valgrind-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/valgrind-users

Reply via email to