diff options
Diffstat (limited to 'example/jitter/msp430.py')
| -rwxr-xr-x | example/jitter/msp430.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/example/jitter/msp430.py b/example/jitter/msp430.py index 36e45421..1ecb4cef 100755 --- a/example/jitter/msp430.py +++ b/example/jitter/msp430.py @@ -1,5 +1,6 @@ #! /usr/bin/env python2 #-*- coding:utf-8 -*- +from __future__ import print_function from argparse import ArgumentParser from miasm2.analysis import debugging from miasm2.jitter.csts import * @@ -39,12 +40,16 @@ def jit_msp430_binary(args): trace_new_blocks=args.log_newbloc ) - myjit.vm.add_memory_page(0, PAGE_READ | PAGE_WRITE, open(filepath, "rb").read()) + myjit.vm.add_memory_page( + 0, + PAGE_READ | PAGE_WRITE, + open(filepath, "rb").read() + ) myjit.add_breakpoint(0x1337, lambda _: exit(0)) # for stack - myjit.vm.add_memory_page(0xF000, PAGE_READ | PAGE_WRITE, "\x00"*0x1000) + myjit.vm.add_memory_page(0xF000, PAGE_READ | PAGE_WRITE, b"\x00"*0x1000) myjit.cpu.SP = 0xF800 |