* readline.c (_rl_output_character_function), display.c:
[deliverable/binutils-gdb.git] / readline / readline.c
index 00af9d6421245c094d1ec2f9ea9542058154f7d9..c8b19e3dd422b17ecb8c66b015bca95c6373133c 100644 (file)
@@ -88,7 +88,7 @@ extern int rl_complete_with_tilde_expansion;
 /* Forward declarations used in this file. */
 void rl_dispatch ();
 void free_history_entry ();
-void _rl_output_character_function ();
+int _rl_output_character_function ();
 void _rl_set_screen_size ();
 
 #if !defined (_GO32_)
@@ -224,6 +224,8 @@ static int defining_kbd_macro = 0;
    emacs_meta_keymap or vi_escape_keymap. */
 int _rl_convert_meta_chars_to_ascii = 1;
 
+/* Non-zero tells rl_delete_text and rl_insert_text to not add to
+   the undo list. */
 static int doing_an_undo;
 \f
 /* **************************************************************** */
@@ -1235,7 +1237,7 @@ init_terminal_io (terminal_name)
 
   screenwidth = screenheight = 0;
 
-  term_xn = tgetflag ("am", &buffer) && tgetflag ("xn", &buffer);
+  term_xn = tgetflag ("am") && tgetflag ("xn");
 
   _rl_set_screen_size (tty, 0);
 
@@ -1319,11 +1321,11 @@ init_terminal_io (terminal_name)
 }
 
 /* A function for the use of tputs () */
-void
+int
 _rl_output_character_function (c)
      int c;
 {
-  putc (c, out_stream);
+  return putc (c, out_stream);
 }
 
 /* Write COUNT characters from STRING to the output stream. */
@@ -2277,10 +2279,6 @@ rl_transpose_chars (count)
 /*                                                                 */
 /* **************************************************************** */
 
-/* Non-zero tells rl_delete_text and rl_insert_text to not add to
-   the undo list. */
-static int doing_an_undo = 0;
-
 /* The current undo list for THE_LINE. */
 UNDO_LIST *rl_undo_list = (UNDO_LIST *)NULL;
 
@@ -3063,6 +3061,15 @@ rl_getc (stream)
     }
 }
 
+char *
+_rl_savestring (str)
+     char *str;
+{
+  char *copy = (char*) xmalloc (strlen (str) + 1);
+  strcpy (copy, str);
+  return copy;
+}
+
 #if defined (STATIC_MALLOC)
 \f
 /* **************************************************************** */
This page took 0.025413 seconds and 4 git commands to generate.