*always* set result

Otherwise KeyboardInterrupt leads to UnboundLocalError.