diff options
| author | Camille Mougey <commial@gmail.com> | 2018-09-28 09:30:23 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-09-28 09:30:23 +0200 |
| commit | 9c8596646ba6150694deb984f25aaad73d2c7125 (patch) | |
| tree | 35e52073cea394d3e66dfa89a53d81987869abe9 /miasm2/core | |
| parent | a5ab3c338e09da5c3e2fe871f1f13e6e37464fa1 (diff) | |
| parent | 846d316efab8b8b654eee58b952cdf1ba2d3eb42 (diff) | |
| download | miasm-9c8596646ba6150694deb984f25aaad73d2c7125.tar.gz miasm-9c8596646ba6150694deb984f25aaad73d2c7125.zip | |
Merge pull request #852 from serpilliere/fix_lgtm_2
Code cleaning: lgtm.com
Diffstat (limited to '')
| -rw-r--r-- | miasm2/core/asmblock.py | 1 | ||||
| -rw-r--r-- | miasm2/core/cpu.py | 2 | ||||
| -rw-r--r-- | miasm2/core/ctypesmngr.py | 3 | ||||
| -rw-r--r-- | miasm2/core/types.py | 3 |
4 files changed, 7 insertions, 2 deletions
diff --git a/miasm2/core/asmblock.py b/miasm2/core/asmblock.py index 2f336617..97113be1 100644 --- a/miasm2/core/asmblock.py +++ b/miasm2/core/asmblock.py @@ -169,7 +169,6 @@ class AsmBlock(object): def split(self, loc_db, offset): loc_key = loc_db.get_or_create_offset_location(offset) log_asmblock.debug('split at %x', offset) - i = -1 offsets = [x.offset for x in self.lines] offset = loc_db.get_location_offset(loc_key) if offset not in offsets: diff --git a/miasm2/core/cpu.py b/miasm2/core/cpu.py index 071991b7..813ac47d 100644 --- a/miasm2/core/cpu.py +++ b/miasm2/core/cpu.py @@ -684,7 +684,7 @@ class m_arg(object): self.expr = expr return start, stop - def asm_ast_to_expr(self, arg, loc_db): + def asm_ast_to_expr(self, arg, loc_db, **kwargs): raise NotImplementedError("Virtual") diff --git a/miasm2/core/ctypesmngr.py b/miasm2/core/ctypesmngr.py index ef14451f..5daf8950 100644 --- a/miasm2/core/ctypesmngr.py +++ b/miasm2/core/ctypesmngr.py @@ -36,6 +36,9 @@ class CTypeBase(object): def _typerepr(self): return self.__repr + def __eq__(self, other): + raise NotImplementedError("Abstract method") + def __ne__(self, other): return not self.__eq__(other) diff --git a/miasm2/core/types.py b/miasm2/core/types.py index e6ba1ccf..a60077ac 100644 --- a/miasm2/core/types.py +++ b/miasm2/core/types.py @@ -340,6 +340,9 @@ class Type(object): def __neq__(self, other): return not self == other + def __eq__(self, other): + raise NotImplementedError("Abstract method") + def __ne__(self, other): return not self.__eq__(other) |