Fixed nasty bug where file writes with start offsets in the range
commit20ffcc6ebbb3eeb68f4bd163aa8c58bfc88ffc4d
authorJeremy Allison <jra@samba.org>
Tue, 3 Dec 2002 08:03:46 +0000 (3 08:03 +0000)
committerJeremy Allison <jra@samba.org>
Tue, 3 Dec 2002 08:03:46 +0000 (3 08:03 +0000)
treef2fb7928aab86f537be1093bdc2d2ea580ac0352
parent4f05f759429404a0d81a4b573bf7487ec3cb3b80
Fixed nasty bug where file writes with start offsets in the range
0x80000000 -> 0xFFFFFFFF would fail as they were being cast
from IVAL (uint32) to SMB_OFF_T (off_t or off64_t, both *signed* types).
The sign extension would cause the offset to be treated as negative.
Thanks to Herb for helping me track this one down (IRIX is good for large
file tests :-).
Jeremy.
source/include/includes.h
source/include/proto.h
source/smbd/blocking.c
source/smbd/nttrans.c
source/smbd/reply.c