diff --git a/pwndbg/commands/procinfo.py b/pwndbg/commands/procinfo.py
index 0afed97d9..d4b0061a9 100644
--- a/pwndbg/commands/procinfo.py
+++ b/pwndbg/commands/procinfo.py
@@ -28,7 +28,7 @@ def procinfo():
Display information about the running process.
"""
if not psutil:
- print "psutil required but not installed"
+ print("psutil required but not installed")
return
exe = repr(str(pwndbg.auxv.get()['AT_EXECFN']))
diff --git a/pwndbg/ida.py b/pwndbg/ida.py
index e63def024..99948ce68 100644
--- a/pwndbg/ida.py
+++ b/pwndbg/ida.py
@@ -23,9 +23,11 @@ try:
except:
import xmlrpclib
+
+xmlrpclib.Marshaller.dispatch[int] = lambda _, v, w: w("%d" % v)
+
if pwndbg.compat.python2:
- xmlrpclib.Marshaller.dispatch[type(0L)] = lambda _, v, w: w("%d" % v)
- xmlrpclib.Marshaller.dispatch[type(0)] = lambda _, v, w: w("%d" % v)
+ xmlrpclib.Marshaller.dispatch[long] = lambda _, v, w: w("%d" % v)
_ida = None