NetBSD-Bugs archive

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

lib/54280: libedit: rl_completer_quote_characters should be const for readline compatibility



>Number:         54280
>Category:       lib
>Synopsis:       libedit: rl_completer_quote_characters should be const for readline compatibility
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    lib-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Jun 06 20:40:00 +0000 2019
>Originator:     Jonathan Perkins
>Release:        Sources as of 2019/06/06
>Organization:
Google
>Environment:
>Description:
For compatibility with readline:
extern char		*rl_completer_quote_characters;
should be
extern const char	*rl_completer_quote_characters;
>How-To-Repeat:

>Fix:
--- old/libedit/readline/readline.h
+++ new/libedit/readline/readline.h
@@ -108,7 +108,7 @@ extern int		 history_base, history_lengt
 extern int		 max_input_history;
 extern const char	*rl_basic_word_break_characters;
 extern char		*rl_completer_word_break_characters;
-extern char		*rl_completer_quote_characters;
+extern const char	*rl_completer_quote_characters;
 extern rl_compentry_func_t *rl_completion_entry_function;
 extern char		*(*rl_completion_word_break_hook)(void);
 extern rl_completion_func_t *rl_attempted_completion_function;
--- old/libedit/readline.c
+++ new/libedit/readline.c
@@ -107,7 +107,7 @@ int rl_inhibit_completion = 0;
 int rl_attempted_completion_over = 0;
 const char *rl_basic_word_break_characters = break_chars;
 char *rl_completer_word_break_characters = NULL;
-char *rl_completer_quote_characters = NULL;
+const char *rl_completer_quote_characters = NULL;
 rl_compentry_func_t *rl_completion_entry_function = NULL;
 char *(*rl_completion_word_break_hook)(void) = NULL;
 rl_completion_func_t *rl_attempted_completion_function = NULL;



Home | Main Index | Thread Index | Old Index