[issue13130] test_gdb: attempt to dereference a generic pointer

Antoine Pitrou report at bugs.python.org
Sat Oct 8 18:21:04 CEST 2011


Antoine Pitrou <pitrou at free.fr> added the comment:

Following patch seems to fix it:

diff --git a/Tools/gdb/libpython.py b/Tools/gdb/libpython.py
--- a/Tools/gdb/libpython.py
+++ b/Tools/gdb/libpython.py
@@ -1152,7 +1152,7 @@ class PyUnicodeObjectPtr(PyObjectPtr):
                     field_str = field_str.cast(_type_unsigned_char_ptr)
                 elif repr_kind == 2:
                     field_str = field_str.cast(_type_unsigned_short_ptr)
-                elif repr_kind == 3:
+                elif repr_kind == 4:
                     field_str = field_str.cast(_type_unsigned_int_ptr)
         else:
             # Python 3.2 and earlier

----------
nosy: +pitrou

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue13130>
_______________________________________


More information about the Python-bugs-list mailing list