diff options
| author | KyleMiles <krm504@nyu.edu> | 2022-01-27 22:43:28 -0500 |
|---|---|---|
| committer | KyleMiles <krm504@nyu.edu> | 2022-01-28 00:24:06 -0500 |
| commit | 6812c973c9fa9b4ad642ab81856c05f87bd6fcc4 (patch) | |
| tree | dace4156d03148bcaf02df138ab4e0d93e61bc6f /python/examples/cli_dis.py | |
| parent | 519c9db22367f2659d1a54599fab47e6313be06e (diff) | |
Format All Files
Diffstat (limited to 'python/examples/cli_dis.py')
| -rwxr-xr-x | python/examples/cli_dis.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/python/examples/cli_dis.py b/python/examples/cli_dis.py index 8f863db3..cbd4b8f1 100755 --- a/python/examples/cli_dis.py +++ b/python/examples/cli_dis.py @@ -55,12 +55,12 @@ archName = sys.argv[1] bytesList = sys.argv[2:] # parse byte arguments -data = b''.join(list(map(lambda x: int(x,16).to_bytes(1,'big'), bytesList))) +data = b''.join(list(map(lambda x: int(x, 16).to_bytes(1, 'big'), bytesList))) # disassemble arch = binaryninja.Architecture[archName] toksAndLen = arch.get_instruction_text(data, 0) -if not toksAndLen or toksAndLen[1]==0: +if not toksAndLen or toksAndLen[1] == 0: print('disassembly failed') sys.exit(-1) @@ -68,4 +68,3 @@ if not toksAndLen or toksAndLen[1]==0: toks = toksAndLen[0] strs = map(lambda x: x.text, toks) print(GREEN, ''.join(strs), NORMAL) - |
