diff options
author | Hin-Tak Leung <hintak_leung@yahoo.co.uk> | 2010-03-05 00:05:13 +0000 |
---|---|---|
committer | Hin-Tak Leung <hintak_leung@yahoo.co.uk> | 2010-03-05 00:05:13 +0000 |
commit | 22c074162c30b8ca2a83559f756153467aed2b9b (patch) | |
tree | cacdc508477fbe854791b53cd9c8be46fd0265d9 /tools | |
parent | b3372e0c1fb55e3ec089dd60e08bc29340afc811 (diff) |
allow the look-up and interpretation of uint32 attribute values in addition to byte attribute values; part of fix to 690083
git-svn-id: http://svn.ghostscript.com/ghostscript/trunk@10860 a1074d23-0009-0410-80fe-cf8c14f379e6
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/pxldis.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/tools/pxldis.py b/tools/pxldis.py index a353dfab2..09e5977de 100755 --- a/tools/pxldis.py +++ b/tools/pxldis.py @@ -749,7 +749,7 @@ class pxl_dis: print k, if pxl_enumerations_dict.has_key(k): print "//", - searchstr = "=" + str(self.saved_ubyte) + searchstr = "=" + str(self.saved_value) enum = pxl_enumerations_dict[k] for value in enum: if ( value[value.index('='):] == searchstr ): @@ -787,8 +787,9 @@ class pxl_dis: print "%f" % self.unpack(self.unpack_string, self.data[self.index:self.index+size]), else: print "%d" % self.unpack(self.unpack_string, self.data[self.index:self.index+size]), - if ( self.unpack_string == 'B' and size == 1 ): - self.saved_ubyte = self.unpack(self.unpack_string, self.data[self.index:self.index+size])[0] + if (( self.unpack_string == 'B' and size == 1 ) or \ + ( self.unpack_string == 'I' and size == 4 )): + self.saved_value = self.unpack(self.unpack_string, self.data[self.index:self.index+size])[0] self.index = self.index + self.size_of_element return 1 return 0 |