This commit is contained in:
Zach Riggle 2015-04-11 12:45:28 -07:00
parent 07159546bd
commit 8a44b111e3
1 changed files with 1 additions and 1 deletions

View File

@ -53,7 +53,7 @@ def address(symbol):
try:
result = gdb.execute('info address %s' % symbol, to_string=True, from_tty=False)
result = result.split()
address = (r for r in result if r.startswith('0x')).next()
address = next(r for r in result if r.startswith('0x'))
return int(address, 0)
except gdb.error:
return None