|
|
|
@ -569,8 +569,11 @@ def context_disasm(target=sys.stdout, with_banner=True, width=None):
|
|
|
|
if cs is not None and cs.syntax != syntax:
|
|
|
|
if cs is not None and cs.syntax != syntax:
|
|
|
|
pwndbg.lib.memoize.reset()
|
|
|
|
pwndbg.lib.memoize.reset()
|
|
|
|
|
|
|
|
|
|
|
|
banner = [pwndbg.ui.banner("disasm", target=target, width=width)]
|
|
|
|
arch = pwndbg.gdblib.arch.current
|
|
|
|
emulate = bool(pwndbg.config.emulate)
|
|
|
|
emulate = bool(pwndbg.config.emulate)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
info = ' / %s / set emulate %s' % (arch, 'on' if emulate else 'off')
|
|
|
|
|
|
|
|
banner = [pwndbg.ui.banner("disasm", target=target, width=width, extra=info)]
|
|
|
|
result = pwndbg.commands.nearpc.nearpc(to_string=True, emulate=emulate, lines=code_lines // 2)
|
|
|
|
result = pwndbg.commands.nearpc.nearpc(to_string=True, emulate=emulate, lines=code_lines // 2)
|
|
|
|
|
|
|
|
|
|
|
|
# If we didn't disassemble backward, try to make sure
|
|
|
|
# If we didn't disassemble backward, try to make sure
|
|
|
|
|