# HG changeset patch # User Benoit Boissinot # Date 1257042370 -3600 # Node ID 57cee011ffcb32de284ae575c9b9899de1f78c43 # Parent dd5a16ad420e6d5845d45dc7bde717a90900ccc2 bisect: no need to save the state if it wasn't changed diff -r dd5a16ad420e -r 57cee011ffcb mercurial/commands.py --- a/mercurial/commands.py Sun Nov 01 02:57:11 2009 +0100 +++ b/mercurial/commands.py Sun Nov 01 03:26:10 2009 +0100 @@ -370,14 +370,14 @@ # update state node = repo.lookup(rev or '.') - if good: - state['good'].append(node) - elif bad: - state['bad'].append(node) - elif skip: - state['skip'].append(node) - - hbisect.save_state(repo, state) + if good or bad or skip: + if good: + state['good'].append(node) + elif bad: + state['bad'].append(node) + elif skip: + state['skip'].append(node) + hbisect.save_state(repo, state) if not check_state(state): return