From 1734e8a1491ef831c83c2620b6b0f4a590b67c1f Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Fri, 11 Apr 2014 12:51:15 +0200 Subject: [PATCH] Fix crash in tab completion Fixes #1. Patch by Maxdamantus. --- nix-repl.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/nix-repl.cc b/nix-repl.cc index ef9be417a..8049008d1 100644 --- a/nix-repl.cc +++ b/nix-repl.cc @@ -216,8 +216,10 @@ void NixRepl::completePrefix(string prefix) } catch (ParseError & e) { // Quietly ignore parse errors. - }catch (EvalError & e) { + } catch (EvalError & e) { // Quietly ignore evaluation errors. + } catch (UndefinedVarError & e) { + // Quietly ignore undefined variable errors. } } }