diff options
| author | Peter LaFosse <peter@vector35.com> | 2018-03-05 16:09:30 -0500 |
|---|---|---|
| committer | Ryan Snyder <ryan@vector35.com> | 2018-07-10 18:11:08 -0400 |
| commit | d4d1fbb390c9a31045cea8e612c02e242d11c438 (patch) | |
| tree | 11a1fcd229d1efc81440080ae0a26dda67b584f6 /python/update.py | |
| parent | 8849fb2b2b8dc824bd3f17ce1026a04856477a94 (diff) | |
Additional changes for python 2/3 compatibility
Diffstat (limited to 'python/update.py')
| -rw-r--r-- | python/update.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/python/update.py b/python/update.py index 1fda149b..560f05ec 100644 --- a/python/update.py +++ b/python/update.py @@ -31,10 +31,10 @@ from six import with_metaclass class _UpdateChannelMetaClass(type): - from binaryninja import startup + @property def list(self): - startup._init_plugins() + binaryninja._init_plugins() count = ctypes.c_ulonglong() errors = ctypes.c_char_p() channels = core.BNGetUpdateChannels(count, errors) @@ -57,7 +57,7 @@ class _UpdateChannelMetaClass(type): return core.BNSetActiveUpdateChannel(value) def __iter__(self): - startup._init_plugins() + binaryninja._init_plugins() count = ctypes.c_ulonglong() errors = ctypes.c_char_p() channels = core.BNGetUpdateChannels(count, errors) @@ -78,7 +78,7 @@ class _UpdateChannelMetaClass(type): raise AttributeError("attribute '%s' is read only" % name) def __getitem__(cls, name): - startup._init_plugins() + binaryninja._init_plugins() count = ctypes.c_ulonglong() errors = ctypes.c_char_p() channels = core.BNGetUpdateChannels(count, errors) @@ -98,7 +98,7 @@ class _UpdateChannelMetaClass(type): class UpdateProgressCallback(object): - from binaryninja import log + def __init__(self, func): self.cb = ctypes.CFUNCTYPE(ctypes.c_bool, ctypes.c_void_p, ctypes.c_ulonglong, ctypes.c_ulonglong)(self.callback) self.func = func |
