diff options
| author | Camille Mougey <commial@gmail.com> | 2015-03-17 17:14:10 +0100 |
|---|---|---|
| committer | Camille Mougey <commial@gmail.com> | 2015-03-17 17:14:10 +0100 |
| commit | f05424a7acf75f7ab490e9df72c0006380def927 (patch) | |
| tree | aa635094f778a420b8d18c85db1ae364bde663dc | |
| parent | 70619a87f16a850f3751c72953014408828df1e3 (diff) | |
| parent | ec15141002e54222f0bc7b50cda5010ea54684d3 (diff) | |
| download | miasm-f05424a7acf75f7ab490e9df72c0006380def927.tar.gz miasm-f05424a7acf75f7ab490e9df72c0006380def927.zip | |
Merge pull request #114 from serpilliere/fix_vm_import
Jitter: vmmngr may not be present (for example in IDA python)
| -rw-r--r-- | miasm2/jitter/jitload.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/miasm2/jitter/jitload.py b/miasm2/jitter/jitload.py index 346746e8..7fe7e5ac 100644 --- a/miasm2/jitter/jitload.py +++ b/miasm2/jitter/jitload.py @@ -8,7 +8,6 @@ from miasm2.jitter.csts import * from miasm2.core.utils import * from miasm2.core.bin_stream import bin_stream_vm from miasm2.ir.ir2C import init_arch_C -from miasm2.jitter import VmMngr hnd = logging.StreamHandler() hnd.setFormatter(logging.Formatter("[%(levelname)s]: %(message)s")) @@ -34,6 +33,12 @@ try: except ImportError: log.error('cannot import jit python') +try: + from miasm2.jitter import VmMngr +except ImportError: + log.error('cannot import VmMngr') + + def named_arguments(func): """Function decorator to allow the use of .func_args_*() methods with either the number of arguments or the list of the argument |