Bug in py32win manual for file_locking for Python 2.4

Nick Coghlan ncoghlan at email.com
Sat Dec 4 09:33:46 EST 2004


Pekka Niiranen wrote:
> However, using
> highbits=0x7fff0000 # equals hex(sys.maxint)
> gives no errors, but does locking work if
> highbits are not exactly 0xffff0000?

Try using highbits=-0x7fff0000 as your mask. That should set the MSB without 
tripping over the sys.maxint limit.

Cheers,
Nick.



More information about the Python-list mailing list