Message205544
Here is a work-in-progress patch.
PyMarshal_ReadShortFromFile() and PyMarshal_ReadLongFromFile() are still wrong: new Unsigned version should be added to marshal.c. I don't know if a C cast to unsigned is enough because long can be larger than 32-bit (ex: on Linux 64-bit):
#if SIZEOF_LONG > 4
/* Sign extension for 64-bit machines */
x |= -(x & 0x80000000L);
#endif
I didn't test my patch. Anyone interested to finish the patch? |
|
Date |
User |
Action |
Args |
2013-12-08 11:10:28 | vstinner | set | recipients:
+ vstinner, brett.cannon, gregory.p.smith, christian.heimes, serhiy.storchaka |
2013-12-08 11:10:28 | vstinner | set | messageid: <1386501028.03.0.46604243691.issue19883@psf.upfronthosting.co.za> |
2013-12-08 11:10:28 | vstinner | link | issue19883 messages |
2013-12-08 11:10:27 | vstinner | create | |
|