aboutsummaryrefslogtreecommitdiff
path: root/src/libcmd/repl.cc
diff options
context:
space:
mode:
authorJohn Ericson <git@JohnEricson.me>2022-11-25 08:14:32 -0500
committerGitHub <noreply@github.com>2022-11-25 08:14:32 -0500
commit26534f141cb52adf0135e86c71628cdef844a57a (patch)
treedff8140578d26993973cb8baf334948664b36660 /src/libcmd/repl.cc
parent13f2a6f38db44385ae1c7d3d01170149de328abb (diff)
parentbc9692a6b701fffe25d2e3b1d16f00edd596930f (diff)
Merge branch 'master' into indexed-store-path-outputs
Diffstat (limited to 'src/libcmd/repl.cc')
-rw-r--r--src/libcmd/repl.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/libcmd/repl.cc b/src/libcmd/repl.cc
index df8932087..bb254ff8d 100644
--- a/src/libcmd/repl.cc
+++ b/src/libcmd/repl.cc
@@ -384,6 +384,10 @@ StringSet NixRepl::completePrefix(const std::string & prefix)
i++;
}
} else {
+ /* Temporarily disable the debugger, to avoid re-entering readline. */
+ auto debug_repl = state->debugRepl;
+ state->debugRepl = nullptr;
+ Finally restoreDebug([&]() { state->debugRepl = debug_repl; });
try {
/* This is an expression that should evaluate to an
attribute set. Evaluate it to get the names of the