diff --git a/sys/include/shell.h b/sys/include/shell.h index ac8c808d38..ff392395be 100644 --- a/sys/include/shell.h +++ b/sys/include/shell.h @@ -50,7 +50,7 @@ extern "C" { * Instead terminate RIOT, which is also the behavior a user would * expect from a CLI application. */ -# if defined(CPU_NATIVE) +# if defined(CPU_NATIVE) && !IS_ACTIVE(MODULE_SHELL_LOCK) # define CONFIG_SHELL_SHUTDOWN_ON_EXIT 1 # else # define CONFIG_SHELL_SHUTDOWN_ON_EXIT 0 diff --git a/tests/sys/shell_lock/Makefile b/tests/sys/shell_lock/Makefile index a9da2d0033..29bebcdd80 100644 --- a/tests/sys/shell_lock/Makefile +++ b/tests/sys/shell_lock/Makefile @@ -12,10 +12,6 @@ CFLAGS += -DCONFIG_SHELL_LOCK_PASSWORD=\"password\" CFLAGS += -DCONFIG_SHELL_LOCK_AUTO_LOCK_TIMEOUT_MS=7000 endif -# This config defaults to 1 on native, such that pm_off() would be called as soon as -# shell_run_once is terminated in shell_run_forever. We do not want this behavior for this test. -CFLAGS += -DCONFIG_SHELL_SHUTDOWN_ON_EXIT=0 - # test_utils_interactive_sync_shell assumes that the prompt is always '> ' which breaks # with the password prompt of the shell_lock module which is different from the shell's prompt DISABLE_MODULE += test_utils_interactive_sync_shell