Whole file

jmcnamara/XlsxWriter

The author described this change as image: fix signedness issue with large gifs. It counts as a record because the check below fails on the code as it stood at 630854d95 and passes on 22302b3d2, with nothing else changed between the two runs.

Fix saved2026-07-02
Sharing licenceBSD-2-Clause · LICENSE.txt
Change size+2 2

What the code was meant to do, written into the code itself as a save note

image: fix signedness issue with large gifs

The change

334334 x_dpi = DEFAULT_DPI
335335 y_dpi = DEFAULT_DPI
336336
337- width = unpack("<h", data[6:8])[0]
338- height = unpack("<h", data[8:10])[0]
337+ width = unpack("<H", data[6:8])[0]
338+ height = unpack("<H", data[8:10])[0]
339339
340340 return "gif", width, height, x_dpi, y_dpi
341341

The check that tells the two apart

failpass·xlsxwriter/test/image/test_image_class01.py::TestImageProperties::test_image_properties06

Check file xlsxwriter/test/image/test_image_class01.py, taken without changes from the fix and copied onto the older code, so the exact same check runs against both versions.

Origin and history

The code before it630854d956b691ad7a2f082bf22c66db72cb21b8
Broken version dated2026-07-02
Modulexlsxwriter.image
Units changedImage
Fingerprint4a350bbefcf0ed86
Checked2026-08-18 by goldset/0.1

Every field above is generated by our program. None of it is written by hand.

Other bugs found in jmcnamara/XlsxWriter