fix bug saving stop-hook index

This commit is contained in:
Zachary Cutlip 2021-01-29 12:19:56 -08:00
parent dcee648452
commit ff902379f5
1 changed files with 4 additions and 2 deletions

View File

@ -573,8 +573,10 @@ if HAVE_LLDB:
output = self.adaptor.command('target stop-hook add -o \'voltron stopped\'')
try:
# hahaha this sucks
self.hook_idx = int(res.GetOutput().strip().split()[2][1:])
except:
log.debug("Saving hook index for unregistering.")
self.hook_idx = int(output.split()[2][1:])
except Exception as e:
log.warning(f"Exception when saving hook index for unregistering. {e}")
pass
self.registered = True
if not quiet: