X-Git-Url: https://git.wh0rd.org/?p=patches.git;a=blobdiff_plain;f=readline-5.1-cleanups.patch;fp=readline-5.1-cleanups.patch;h=cf1297c824811791e2cd65bd0b3002886eb165e1;hp=0000000000000000000000000000000000000000;hb=b53d1f41b32c8078c755a63c7bf0d2852263ee99;hpb=6d7b707a99652eefa9b245d8f1e0053f3583c79c diff --git a/readline-5.1-cleanups.patch b/readline-5.1-cleanups.patch new file mode 100644 index 0000000..cf1297c --- /dev/null +++ b/readline-5.1-cleanups.patch @@ -0,0 +1,133 @@ +--- readline-5.1.orig/bind.c 2005-10-14 11:04:27.000000000 -0400 ++++ readline-5.1/bind.c 2005-12-12 15:49:19.000000000 -0500 +@@ -1506,8 +1506,6 @@ rl_variable_value (name) + const char *name; + { + register int i; +- int v; +- char *ret; + + /* Check for simple variables first. */ + i = find_boolean_var (name); +@@ -2170,7 +2168,6 @@ _rl_get_string_variable_value (name) + { + static char numbuf[32]; + char *ret; +- int n; + + if (_rl_stricmp (name, "bell-style") == 0) + { +--- readline-5.1.orig/callback.c 2005-05-24 14:19:04.000000000 -0400 ++++ readline-5.1/callback.c 2005-12-12 19:32:00.000000000 -0500 +@@ -43,6 +43,7 @@ + #include "rldefs.h" + #include "readline.h" + #include "rlprivate.h" ++#include "xmalloc.h" + + /* Private data for callback registration functions. See comments in + rl_callback_read_char for more details. */ +--- readline-5.1.orig/display.c 2005-11-30 14:05:02.000000000 -0500 ++++ readline-5.1/display.c 2005-12-12 16:00:32.000000000 -0500 +@@ -1164,7 +1166,7 @@ update_line (old, new, current_line, oma + int col_lendiff, col_temp; + #if defined (HANDLE_MULTIBYTE) + mbstate_t ps_new, ps_old; +- int new_offset, old_offset, tmp; ++ int new_offset, old_offset; + #endif + + /* If we're at the right edge of a terminal that supports xn, we're +--- readline-5.1.orig/isearch.c 2005-10-07 18:21:32.000000000 -0400 ++++ readline-5.1/isearch.c 2005-12-12 15:55:37.000000000 -0500 +@@ -67,10 +67,6 @@ static _rl_search_cxt *_rl_isearch_init + static void _rl_isearch_fini PARAMS((_rl_search_cxt *)); + static int _rl_isearch_cleanup PARAMS((_rl_search_cxt *, int)); + +-/* Last line found by the current incremental search, so we don't `find' +- identical lines many times in a row. */ +-static char *prev_line_found; +- + /* Last search string and its length. */ + static char *last_isearch_string; + static int last_isearch_string_len; +--- readline-5.1.orig/misc.c 2005-05-15 15:27:09.000000000 -0400 ++++ readline-5.1/misc.c 2005-12-12 16:09:28.000000000 -0500 +@@ -212,6 +212,8 @@ rl_digit_loop () + if (r <= 0 || (RL_ISSTATE (RL_STATE_NUMERICARG) == 0)) + break; + } ++ ++ return 0; + } + + /* Create a default argument. */ +--- readline-5.1.orig/readline.c 2005-07-04 22:29:35.000000000 -0400 ++++ readline-5.1/readline.c 2005-12-12 15:47:58.000000000 -0500 +@@ -85,7 +85,7 @@ static void bind_arrow_keys_internal PAR + static void bind_arrow_keys PARAMS((void)); + + static void readline_default_bindings PARAMS((void)); +-static void reset_default_bindings PARAMS((void)); ++/* static void reset_default_bindings PARAMS((void)); */ + + static int _rl_subseq_result PARAMS((int, Keymap, int, int)); + static int _rl_subseq_getchar PARAMS((int)); +@@ -1054,6 +1054,7 @@ readline_default_bindings () + + /* Reset the default bindings for the terminal special characters we're + interested in back to rl_insert and read the new ones. */ ++/* Unused function + static void + reset_default_bindings () + { +@@ -1063,6 +1064,7 @@ reset_default_bindings () + rl_tty_set_default_bindings (_rl_keymap); + } + } ++*/ + + /* Bind some common arrow key sequences in MAP. */ + static void +--- readline-5.1.orig/rltty.c 2005-11-13 21:07:55.000000000 -0500 ++++ readline-5.1/rltty.c 2005-12-12 15:48:41.000000000 -0500 +@@ -933,7 +933,6 @@ rltty_set_default_bindings (kmap) + #if !defined (NO_TTY_DRIVER) + TIOTYPE ttybuff; + int tty; +- static int called = 0; + + tty = fileno (rl_instream); + +--- readline-5.1.orig/search.c 2005-08-27 11:52:36.000000000 -0400 ++++ readline-5.1/search.c 2005-12-12 15:48:21.000000000 -0500 +@@ -70,7 +70,6 @@ static int rl_history_search_pos; + static char *history_search_string; + static int history_string_size; + +-static UNDO_LIST *noninc_saved_undo_list; + static void make_history_line_current PARAMS((HIST_ENTRY *)); + static int noninc_search_from_pos PARAMS((char *, int, int)); + static int noninc_dosearch PARAMS((char *, int)); +--- readline-5.1.orig/text.c 2005-09-24 19:06:07.000000000 -0400 ++++ readline-5.1/text.c 2005-12-12 15:50:29.000000000 -0500 +@@ -1239,7 +1239,7 @@ rl_change_case (count, op) + #if defined (HANDLE_MULTIBYTE) + wchar_t wc, nwc; + char mb[MB_LEN_MAX+1]; +- int mblen, p; ++ int mblen; + mbstate_t ps; + #endif + +--- readline-5.1.orig/vi_mode.c 2005-11-01 11:11:04.000000000 -0500 ++++ readline-5.1/vi_mode.c 2005-12-12 15:48:15.000000000 -0500 +@@ -1111,7 +1111,7 @@ int + rl_vi_rubout (count, key) + int count, key; + { +- int p, opoint; ++ int opoint; + + if (count < 0) + return (rl_vi_delete (-count, key));