[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
silence some compiler warnings about readline dead code
From: |
Eric Blake |
Subject: |
silence some compiler warnings about readline dead code |
Date: |
Fri, 23 Jan 2015 17:11:13 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0 |
Noticed this while fixing compiler warnings for readline on cygwin:
diff --git i/lib/readline/readline.c w/lib/readline/readline.c
index abb29a0..9bb552f 100644
--- i/lib/readline/readline.c
+++ w/lib/readline/readline.c
@@ -1,7 +1,7 @@
/* readline.c -- a general facility for reading lines of input
with emacs style editing and completion. */
-/* Copyright (C) 1987-2013 Free Software Foundation, Inc.
+/* Copyright (C) 1987-2013, 2015 Free Software Foundation, Inc.
This file is part of the GNU Readline Library (Readline), a library
for reading lines of text with interactive input and history
editing.
@@ -95,7 +95,6 @@ static void bind_arrow_keys_internal PARAMS((Keymap));
static void bind_arrow_keys PARAMS((void));
static void readline_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));
@@ -522,13 +521,16 @@ readline_internal_char ()
readline_internal_charloop ()
#endif
{
- static int lastc, eof_found;
+#ifndef READLINE_CALLBACKS
+ static int eof_found;
+#endif
+ static int lastc;
int c, code, lk;
lastc = -1;
- eof_found = 0;
#if !defined (READLINE_CALLBACKS)
+ eof_found = 0;
while (rl_done == 0)
{
#endif
@@ -1204,18 +1206,6 @@ readline_default_bindings ()
rl_tty_set_default_bindings (_rl_keymap);
}
-/* Reset the default bindings for the terminal special characters we're
- interested in back to rl_insert and read the new ones. */
-static void
-reset_default_bindings ()
-{
- if (_rl_bind_stty_chars)
- {
- rl_tty_unset_default_bindings (_rl_keymap);
- rl_tty_set_default_bindings (_rl_keymap);
- }
-}
-
/* Bind some common arrow key sequences in MAP. */
static void
bind_arrow_keys_internal (map)
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- silence some compiler warnings about readline dead code,
Eric Blake <=