Merge pull request #97 from AntoineD/master

fix loading breakpoint conditions (Issue #87)
This commit is contained in:
Aaron Meurer 2013-11-21 16:07:26 -08:00
commit 79dbc6eed0

View File

@ -460,9 +460,13 @@ def save_breakpoints(bp_list):
"""
histfile = open(get_breakpoints_file_name(), 'w')
bp_list = set([(bp.file, bp.line) for bp in bp_list])
bp_list = set([(bp.file, bp.line, bp.cond) for bp in bp_list])
for bp in bp_list:
histfile.write("b %s:%d\n" % (bp[0], bp[1]))
line = "b %s:%d" % (bp[0], bp[1])
if bp[2]:
line += ", %s" % bp[2]
line += "\n"
histfile.write(line)
histfile.close()
# }}}