[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

rl_filename_quoting_function restoration

From: Grisha Levit
Subject: rl_filename_quoting_function restoration
Date: Thu, 16 Mar 2023 14:32:56 -0400

bash_glob_complete_word modifies rl_filename_quoting_function, which
can fail to be restored if bash_tilde_expand handles a SIGINT while
glob-complete-word is running

Handling the restore in bashline_reset() seems to solve the issue:

diff --git a/bashline.c b/bashline.c
index 2745c4dd..7c3812eb 100644
--- a/bashline.c
+++ b/bashline.c
@@ -685,6 +685,7 @@ bashline_reset (void)
   complete_fullquote = 1;
   rl_filename_quote_characters = default_filename_quote_characters;
   set_filename_bstab (rl_filename_quote_characters);
+  rl_filename_quoting_function = bash_quote_filename;

   set_directory_hook ();
   rl_filename_stat_hook = bash_filename_stat_hook;

reply via email to

[Prev in Thread] Current Thread [Next in Thread]