[Image-SIG] Re: bug in PIL 1.1.4?

Fredrik Lundh fredrik at pythonware.com
Mon Sep 20 08:37:18 CEST 2004


Terry Kerr wrote:
> One of our application users managed to get this traceback.
>
>     * Module PIL.Image, line 1556, in open
>     * Module PIL.ImageFile, line 78, in __init__
>     * Module PIL.FpxImagePlugin, line 63, in _open
>     * Module PIL.OleFileIO, line 253, in __init__
>     * Module PIL.OleFileIO, line 279, in open
>     * Module PIL.OleFileIO, line 298, in loadfat
>
> NameError: global name 'x' is not defined

this has been fixed in 1.1.5:

Index: OleFileIO.py
===================================================================
--- OleFileIO.py        (revision 214)
+++ OleFileIO.py        (revision 261)
@@ -295,7 +296,7 @@
         fat = []
         for i in range(0, len(sect), 4):
             ix = i32(sect, i)
-            if ix == 0xFFFFFFFEL or x == 0xFFFFFFFFL:
+            if ix == 0xFFFFFFFEL or ix == 0xFFFFFFFFL:
                 break
             s = self.getsect(ix)
             fat = fat + map(lambda i, s=s: i32(s, i), range(0, len(s), 4))

</F> 





More information about the Image-SIG mailing list