From 6c29016a0972f20cb0c91a4d9c8020f09baf6293 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Th=C3=A9ophane=20Hufschmitt?= <7226587+thufschmitt@users.noreply.github.com> Date: Tue, 5 Mar 2024 06:58:29 +0100 Subject: Merge pull request #9920 from 9999years/forbid-nested-debuggers Forbid nested debuggers (cherry picked from commit e164b39ee90fd655dbb7f479fdd4fbe38cc883bd) Change-Id: Iff62f40fd251116516a63e2d3f9fb5b21480b16d --- src/libcmd/repl.cc | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) (limited to 'src/libcmd/repl.cc') diff --git a/src/libcmd/repl.cc b/src/libcmd/repl.cc index ab7d7f18c..45b56d012 100644 --- a/src/libcmd/repl.cc +++ b/src/libcmd/repl.cc @@ -233,13 +233,7 @@ ReplExitStatus NixRepl::mainLoop() printMsg(lvlError, e.msg()); } } catch (EvalError & e) { - // in debugger mode, an EvalError should trigger another repl session. - // when that session returns the exception will land here. No need to show it again; - // show the error for this repl session instead. - if (state->debugRepl && !state->debugTraces.empty()) - showDebugTrace(std::cout, state->positions, state->debugTraces.front()); - else - printMsg(lvlError, e.msg()); + printMsg(lvlError, e.msg()); } catch (Error & e) { printMsg(lvlError, e.msg()); } catch (Interrupted & e) { -- cgit v1.2.3