| 1 |
Cleanup misc warnings
|
| 2 |
|
| 3 |
http://lists.gnu.org/archive/html/bug-bash/2005-12/msg00034.html
|
| 4 |
|
| 5 |
--- readline-5.1/bind.c
|
| 6 |
+++ readline-5.1/bind.c
|
| 7 |
@@ -1506,8 +1506,6 @@ rl_variable_value (name)
|
| 8 |
const char *name;
|
| 9 |
{
|
| 10 |
register int i;
|
| 11 |
- int v;
|
| 12 |
- char *ret;
|
| 13 |
|
| 14 |
/* Check for simple variables first. */
|
| 15 |
i = find_boolean_var (name);
|
| 16 |
@@ -2170,7 +2168,6 @@ _rl_get_string_variable_value (name)
|
| 17 |
{
|
| 18 |
static char numbuf[32];
|
| 19 |
char *ret;
|
| 20 |
- int n;
|
| 21 |
|
| 22 |
if (_rl_stricmp (name, "bell-style") == 0)
|
| 23 |
{
|
| 24 |
--- readline-5.1/callback.c
|
| 25 |
+++ readline-5.1/callback.c
|
| 26 |
@@ -43,6 +43,7 @@
|
| 27 |
#include "rldefs.h"
|
| 28 |
#include "readline.h"
|
| 29 |
#include "rlprivate.h"
|
| 30 |
+#include "xmalloc.h"
|
| 31 |
|
| 32 |
/* Private data for callback registration functions. See comments in
|
| 33 |
rl_callback_read_char for more details. */
|
| 34 |
--- readline-5.1/display.c
|
| 35 |
+++ readline-5.1/display.c
|
| 36 |
@@ -1164,7 +1166,7 @@ update_line (old, new, current_line, oma
|
| 37 |
int col_lendiff, col_temp;
|
| 38 |
#if defined (HANDLE_MULTIBYTE)
|
| 39 |
mbstate_t ps_new, ps_old;
|
| 40 |
- int new_offset, old_offset, tmp;
|
| 41 |
+ int new_offset, old_offset;
|
| 42 |
#endif
|
| 43 |
|
| 44 |
/* If we're at the right edge of a terminal that supports xn, we're
|
| 45 |
--- readline-5.1/isearch.c
|
| 46 |
+++ readline-5.1/isearch.c
|
| 47 |
@@ -67,10 +67,6 @@ static _rl_search_cxt *_rl_isearch_init
|
| 48 |
static void _rl_isearch_fini PARAMS((_rl_search_cxt *));
|
| 49 |
static int _rl_isearch_cleanup PARAMS((_rl_search_cxt *, int));
|
| 50 |
|
| 51 |
-/* Last line found by the current incremental search, so we don't `find'
|
| 52 |
- identical lines many times in a row. */
|
| 53 |
-static char *prev_line_found;
|
| 54 |
-
|
| 55 |
/* Last search string and its length. */
|
| 56 |
static char *last_isearch_string;
|
| 57 |
static int last_isearch_string_len;
|
| 58 |
--- readline-5.1/misc.c
|
| 59 |
+++ readline-5.1/misc.c
|
| 60 |
@@ -212,6 +212,8 @@ rl_digit_loop ()
|
| 61 |
if (r <= 0 || (RL_ISSTATE (RL_STATE_NUMERICARG) == 0))
|
| 62 |
break;
|
| 63 |
}
|
| 64 |
+
|
| 65 |
+ return 0;
|
| 66 |
}
|
| 67 |
|
| 68 |
/* Create a default argument. */
|
| 69 |
--- readline-5.1/readline.c
|
| 70 |
+++ readline-5.1/readline.c
|
| 71 |
@@ -85,7 +85,7 @@ static void bind_arrow_keys_internal PAR
|
| 72 |
static void bind_arrow_keys PARAMS((void));
|
| 73 |
|
| 74 |
static void readline_default_bindings PARAMS((void));
|
| 75 |
-static void reset_default_bindings PARAMS((void));
|
| 76 |
+/* static void reset_default_bindings PARAMS((void)); */
|
| 77 |
|
| 78 |
static int _rl_subseq_result PARAMS((int, Keymap, int, int));
|
| 79 |
static int _rl_subseq_getchar PARAMS((int));
|
| 80 |
@@ -1054,6 +1054,7 @@ readline_default_bindings ()
|
| 81 |
|
| 82 |
/* Reset the default bindings for the terminal special characters we're
|
| 83 |
interested in back to rl_insert and read the new ones. */
|
| 84 |
+/* Unused function
|
| 85 |
static void
|
| 86 |
reset_default_bindings ()
|
| 87 |
{
|
| 88 |
@@ -1063,6 +1064,7 @@ reset_default_bindings ()
|
| 89 |
rl_tty_set_default_bindings (_rl_keymap);
|
| 90 |
}
|
| 91 |
}
|
| 92 |
+*/
|
| 93 |
|
| 94 |
/* Bind some common arrow key sequences in MAP. */
|
| 95 |
static void
|
| 96 |
--- readline-5.1/rltty.c
|
| 97 |
+++ readline-5.1/rltty.c
|
| 98 |
@@ -933,7 +933,6 @@ rltty_set_default_bindings (kmap)
|
| 99 |
#if !defined (NO_TTY_DRIVER)
|
| 100 |
TIOTYPE ttybuff;
|
| 101 |
int tty;
|
| 102 |
- static int called = 0;
|
| 103 |
|
| 104 |
tty = fileno (rl_instream);
|
| 105 |
|
| 106 |
--- readline-5.1/search.c
|
| 107 |
+++ readline-5.1/search.c
|
| 108 |
@@ -70,7 +70,6 @@ static int rl_history_search_pos;
|
| 109 |
static char *history_search_string;
|
| 110 |
static int history_string_size;
|
| 111 |
|
| 112 |
-static UNDO_LIST *noninc_saved_undo_list;
|
| 113 |
static void make_history_line_current PARAMS((HIST_ENTRY *));
|
| 114 |
static int noninc_search_from_pos PARAMS((char *, int, int));
|
| 115 |
static int noninc_dosearch PARAMS((char *, int));
|
| 116 |
--- readline-5.1/text.c
|
| 117 |
+++ readline-5.1/text.c
|
| 118 |
@@ -1239,7 +1239,7 @@ rl_change_case (count, op)
|
| 119 |
#if defined (HANDLE_MULTIBYTE)
|
| 120 |
wchar_t wc, nwc;
|
| 121 |
char mb[MB_LEN_MAX+1];
|
| 122 |
- int mblen, p;
|
| 123 |
+ int mblen;
|
| 124 |
mbstate_t ps;
|
| 125 |
#endif
|
| 126 |
|
| 127 |
--- readline-5.1/vi_mode.c
|
| 128 |
+++ readline-5.1/vi_mode.c
|
| 129 |
@@ -1111,7 +1111,7 @@ int
|
| 130 |
rl_vi_rubout (count, key)
|
| 131 |
int count, key;
|
| 132 |
{
|
| 133 |
- int p, opoint;
|
| 134 |
+ int opoint;
|
| 135 |
|
| 136 |
if (count < 0)
|
| 137 |
return (rl_vi_delete (-count, key));
|