Make gdb pretty-printers compatible with Python3

On some systems gdb is linked against python3 where "long" no longer
exists. In this case should be using int.

https://bugzilla.gnome.org/show_bug.cgi?id=720635
This commit is contained in:
Tim Lunn 2013-12-18 07:14:38 +11:00
parent 91d4659bbf
commit d33f72097f
2 changed files with 9 additions and 0 deletions

View File

@ -1,4 +1,8 @@
import gdb
import sys
if sys.version_info[0] >= 3:
long = int
# This is not quite right, as local vars may override symname
def read_global_var (symname):

View File

@ -1,6 +1,11 @@
import os.path
import gdb
import glib
import sys
if sys.version_info[0] >= 3:
long = int
try:
import gdb.backtrace
import gdb.command.backtrace