diff options
| author | serpilliere <serpilliere@users.noreply.github.com> | 2021-12-07 06:53:16 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-12-07 06:53:16 +0100 |
| commit | 0c87b6cc420720dc38156197d064cbc2c1bf848f (patch) | |
| tree | 3d1f3c95500b7d17a8389a5075aa2ca9d414d6fa /miasm/arch/arm/arch.py | |
| parent | 0cd2cad02dd1b300d61bdc985b09de65f92261b4 (diff) | |
| parent | 990df9a9fcb5ae6f1142f49865404e42ec01439c (diff) | |
| download | focaccia-miasm-0c87b6cc420720dc38156197d064cbc2c1bf848f.tar.gz focaccia-miasm-0c87b6cc420720dc38156197d064cbc2c1bf848f.zip | |
Merge pull request #1403 from serpilliere/fix_html
Fix html; Add reg test
Diffstat (limited to 'miasm/arch/arm/arch.py')
| -rw-r--r-- | miasm/arch/arm/arch.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/miasm/arch/arm/arch.py b/miasm/arch/arm/arch.py index affa9866..7b07387c 100644 --- a/miasm/arch/arm/arch.py +++ b/miasm/arch/arm/arch.py @@ -481,7 +481,7 @@ class instruction_arm(instruction): else: r, s = expr.args[0].args if isinstance(s, ExprOp) and s.op in expr2shift_dct: - s = ' '.join( + s_html = ' '.join( str(x) for x in ( color_expr_html(s.args[0], loc_db), @@ -489,14 +489,16 @@ class instruction_arm(instruction): color_expr_html(s.args[1], loc_db) ) ) + else: + s_html = color_expr_html(s, loc_db) if isinstance(expr, ExprOp) and expr.op == 'postinc': o = '[%s]' % color_expr_html(r, loc_db) if s and not (isinstance(s, ExprInt) and int(s) == 0): - o += ', %s' % color_expr_html(s, loc_db) + o += ', %s' % s_html else: if s and not (isinstance(s, ExprInt) and int(s) == 0): - o = '[%s, %s]' % (color_expr_html(r, loc_db), color_expr_html(s, loc_db)) + o = '[%s, %s]' % (color_expr_html(r, loc_db), s_html) else: o = '[%s]' % color_expr_html(r, loc_db) |