From 524c853e5ef0392fcf28e449946e05e7e3046e67 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Tue, 27 Sep 2022 15:48:20 +0100 Subject: [PATCH] patch 9.0.0606: system() opens a terminal window when "!" is in 'guioptions' Problem: system() opens a terminal window when using the GUI and "!" is in 'guioptions'. Solution: Do not use a terminal window when the SHELL_SILENT flag is used. (closes #11202) --- src/os_unix.c | 3 ++- src/version.c | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/os_unix.c b/src/os_unix.c index 1ac6e190b..e86e30837 100644 --- a/src/os_unix.c +++ b/src/os_unix.c @@ -5476,7 +5476,8 @@ mch_call_shell( ch_log(NULL, "executing shell command: %s", cmd); #endif #if defined(FEAT_GUI) && defined(FEAT_TERMINAL) - if (gui.in_use && vim_strchr(p_go, GO_TERMINAL) != NULL) + if (gui.in_use && vim_strchr(p_go, GO_TERMINAL) != NULL + && (options & SHELL_SILENT) == 0) return mch_call_shell_terminal(cmd, options); #endif #ifdef USE_SYSTEM diff --git a/src/version.c b/src/version.c index c9dab4d35..5a4cb9f38 100644 --- a/src/version.c +++ b/src/version.c @@ -699,6 +699,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 606, /**/ 605, /**/ -- 2.40.0