| [112d70e] | 1 | Submitted By: William Harrington (kb0iic at cross-lfs dot org) | 
|---|
|  | 2 | Date: 09-26-2014 | 
|---|
|  | 3 | Initial Package Version: 6.3 | 
|---|
|  | 4 | Origin: Upstream | 
|---|
|  | 5 | Upstream Status: Applied | 
|---|
|  | 6 | Description: Contains all upstream patches up to 6.3-008 | 
|---|
|  | 7 |  | 
|---|
|  | 8 | diff -Naur readline-6.3.orig/display.c readline-6.3/display.c | 
|---|
|  | 9 | --- readline-6.3.orig/display.c 2013-12-27 18:10:56.000000000 +0000 | 
|---|
|  | 10 | +++ readline-6.3/display.c      2014-09-27 00:01:42.959231656 +0000 | 
|---|
|  | 11 | @@ -1637,7 +1637,7 @@ | 
|---|
|  | 12 | /* If we are changing the number of invisible characters in a line, and | 
|---|
|  | 13 | the spot of first difference is before the end of the invisible chars, | 
|---|
|  | 14 | lendiff needs to be adjusted. */ | 
|---|
|  | 15 | -  if (current_line == 0 && !_rl_horizontal_scroll_mode && | 
|---|
|  | 16 | +  if (current_line == 0 && /* !_rl_horizontal_scroll_mode && */ | 
|---|
|  | 17 | current_invis_chars != visible_wrap_offset) | 
|---|
|  | 18 | { | 
|---|
|  | 19 | if (MB_CUR_MAX > 1 && rl_byte_oriented == 0) | 
|---|
|  | 20 | @@ -1825,8 +1825,13 @@ | 
|---|
|  | 21 | else | 
|---|
|  | 22 | _rl_last_c_pos += bytes_to_insert; | 
|---|
|  | 23 |  | 
|---|
|  | 24 | +             /* XXX - we only want to do this if we are at the end of the line | 
|---|
|  | 25 | +                so we move there with _rl_move_cursor_relative */ | 
|---|
|  | 26 | if (_rl_horizontal_scroll_mode && ((oe-old) > (ne-new))) | 
|---|
|  | 27 | -               goto clear_rest_of_line; | 
|---|
|  | 28 | +               { | 
|---|
|  | 29 | +                 _rl_move_cursor_relative (ne-new, new); | 
|---|
|  | 30 | +                 goto clear_rest_of_line; | 
|---|
|  | 31 | +               } | 
|---|
|  | 32 | } | 
|---|
|  | 33 | } | 
|---|
|  | 34 | /* Otherwise, print over the existing material. */ | 
|---|
|  | 35 | @@ -2677,7 +2682,8 @@ | 
|---|
|  | 36 | { | 
|---|
|  | 37 | if (_rl_echoing_p) | 
|---|
|  | 38 | { | 
|---|
|  | 39 | -      _rl_move_vert (_rl_vis_botlin); | 
|---|
|  | 40 | +      if (_rl_vis_botlin > 0)  /* minor optimization plus bug fix */ | 
|---|
|  | 41 | +       _rl_move_vert (_rl_vis_botlin); | 
|---|
|  | 42 | _rl_vis_botlin = 0; | 
|---|
|  | 43 | fflush (rl_outstream); | 
|---|
|  | 44 | rl_restart_output (1, 0); | 
|---|
|  | 45 | diff -Naur readline-6.3.orig/input.c readline-6.3/input.c | 
|---|
|  | 46 | --- readline-6.3.orig/input.c   2014-01-10 20:07:08.000000000 +0000 | 
|---|
|  | 47 | +++ readline-6.3/input.c        2014-09-27 00:01:42.962564981 +0000 | 
|---|
|  | 48 | @@ -534,8 +534,16 @@ | 
|---|
|  | 49 | return (RL_ISSTATE (RL_STATE_READCMD) ? READERR : EOF); | 
|---|
|  | 50 | else if (_rl_caught_signal == SIGHUP || _rl_caught_signal == SIGTERM) | 
|---|
|  | 51 | return (RL_ISSTATE (RL_STATE_READCMD) ? READERR : EOF); | 
|---|
|  | 52 | +      /* keyboard-generated signals of interest */ | 
|---|
|  | 53 | else if (_rl_caught_signal == SIGINT || _rl_caught_signal == SIGQUIT) | 
|---|
|  | 54 | RL_CHECK_SIGNALS (); | 
|---|
|  | 55 | +      /* non-keyboard-generated signals of interest */ | 
|---|
|  | 56 | +      else if (_rl_caught_signal == SIGALRM | 
|---|
|  | 57 | +#if defined (SIGVTALRM) | 
|---|
|  | 58 | +               || _rl_caught_signal == SIGVTALRM | 
|---|
|  | 59 | +#endif | 
|---|
|  | 60 | +             ) | 
|---|
|  | 61 | +        RL_CHECK_SIGNALS (); | 
|---|
|  | 62 |  | 
|---|
|  | 63 | if (rl_signal_event_hook) | 
|---|
|  | 64 | (*rl_signal_event_hook) (); | 
|---|
|  | 65 | diff -Naur readline-6.3.orig/misc.c readline-6.3/misc.c | 
|---|
|  | 66 | --- readline-6.3.orig/misc.c    2012-09-01 22:03:11.000000000 +0000 | 
|---|
|  | 67 | +++ readline-6.3/misc.c 2014-09-27 00:01:42.965898306 +0000 | 
|---|
|  | 68 | @@ -461,6 +461,7 @@ | 
|---|
|  | 69 | saved_undo_list = 0; | 
|---|
|  | 70 | /* Set up rl_line_buffer and other variables from history entry */ | 
|---|
|  | 71 | rl_replace_from_history (entry, 0);   /* entry->line is now current */ | 
|---|
|  | 72 | +         entry->data = 0;                      /* entry->data is now current undo list */ | 
|---|
|  | 73 | /* Undo all changes to this history entry */ | 
|---|
|  | 74 | while (rl_undo_list) | 
|---|
|  | 75 | rl_do_undo (); | 
|---|
|  | 76 | @@ -468,7 +469,6 @@ | 
|---|
|  | 77 | the timestamp. */ | 
|---|
|  | 78 | FREE (entry->line); | 
|---|
|  | 79 | entry->line = savestring (rl_line_buffer); | 
|---|
|  | 80 | -         entry->data = 0; | 
|---|
|  | 81 | } | 
|---|
|  | 82 | entry = previous_history (); | 
|---|
|  | 83 | } | 
|---|
|  | 84 | diff -Naur readline-6.3.orig/patchlevel readline-6.3/patchlevel | 
|---|
|  | 85 | --- readline-6.3.orig/patchlevel        2013-11-15 13:11:11.000000000 +0000 | 
|---|
|  | 86 | +++ readline-6.3/patchlevel     2014-09-27 00:01:42.965898306 +0000 | 
|---|
|  | 87 | @@ -1,3 +1,3 @@ | 
|---|
|  | 88 | # Do not edit -- exists only for use by patch | 
|---|
|  | 89 |  | 
|---|
|  | 90 | -5 | 
|---|
|  | 91 | +8 | 
|---|
|  | 92 | diff -Naur readline-6.3.orig/readline.c readline-6.3/readline.c | 
|---|
|  | 93 | --- readline-6.3.orig/readline.c        2013-10-28 18:58:06.000000000 +0000 | 
|---|
|  | 94 | +++ readline-6.3/readline.c     2014-09-27 00:01:42.945898355 +0000 | 
|---|
|  | 95 | @@ -744,7 +744,8 @@ | 
|---|
|  | 96 | r = _rl_subseq_result (r, cxt->oldmap, cxt->okey, (cxt->flags & KSEQ_SUBSEQ)); | 
|---|
|  | 97 |  | 
|---|
|  | 98 | RL_CHECK_SIGNALS (); | 
|---|
|  | 99 | -  if (r == 0)                  /* success! */ | 
|---|
|  | 100 | +  /* We only treat values < 0 specially to simulate recursion. */ | 
|---|
|  | 101 | +  if (r >= 0 || (r == -1 && (cxt->flags & KSEQ_SUBSEQ) == 0))  /* success! or failure! */ | 
|---|
|  | 102 | { | 
|---|
|  | 103 | _rl_keyseq_chain_dispose (); | 
|---|
|  | 104 | RL_UNSETSTATE (RL_STATE_MULTIKEY); | 
|---|
|  | 105 | @@ -964,7 +965,7 @@ | 
|---|
|  | 106 | #if defined (VI_MODE) | 
|---|
|  | 107 | if (rl_editing_mode == vi_mode && _rl_keymap == vi_movement_keymap && | 
|---|
|  | 108 | key != ANYOTHERKEY && | 
|---|
|  | 109 | -      rl_key_sequence_length == 1 &&   /* XXX */ | 
|---|
|  | 110 | +      _rl_dispatching_keymap == vi_movement_keymap && | 
|---|
|  | 111 | _rl_vi_textmod_command (key)) | 
|---|
|  | 112 | _rl_vi_set_last (key, rl_numeric_arg, rl_arg_sign); | 
|---|
|  | 113 | #endif | 
|---|
|  | 114 | diff -Naur readline-6.3.orig/rltypedefs.h readline-6.3/rltypedefs.h | 
|---|
|  | 115 | --- readline-6.3.orig/rltypedefs.h      2011-03-26 18:53:31.000000000 +0000 | 
|---|
|  | 116 | +++ readline-6.3/rltypedefs.h   2014-09-27 00:01:42.955898330 +0000 | 
|---|
|  | 117 | @@ -26,6 +26,25 @@ | 
|---|
|  | 118 | extern "C" { | 
|---|
|  | 119 | #endif | 
|---|
|  | 120 |  | 
|---|
|  | 121 | +/* Old-style, attempt to mark as deprecated in some way people will notice. */ | 
|---|
|  | 122 | + | 
|---|
|  | 123 | +#if !defined (_FUNCTION_DEF) | 
|---|
|  | 124 | +#  define _FUNCTION_DEF | 
|---|
|  | 125 | + | 
|---|
|  | 126 | +#if defined(__GNUC__) || defined(__clang__) | 
|---|
|  | 127 | +typedef int Function () __attribute__ ((deprecated)); | 
|---|
|  | 128 | +typedef void VFunction () __attribute__ ((deprecated)); | 
|---|
|  | 129 | +typedef char *CPFunction () __attribute__ ((deprecated)); | 
|---|
|  | 130 | +typedef char **CPPFunction () __attribute__ ((deprecated)); | 
|---|
|  | 131 | +#else | 
|---|
|  | 132 | +typedef int Function (); | 
|---|
|  | 133 | +typedef void VFunction (); | 
|---|
|  | 134 | +typedef char *CPFunction (); | 
|---|
|  | 135 | +typedef char **CPPFunction (); | 
|---|
|  | 136 | +#endif | 
|---|
|  | 137 | + | 
|---|
|  | 138 | +#endif /* _FUNCTION_DEF */ | 
|---|
|  | 139 | + | 
|---|
|  | 140 | /* New style. */ | 
|---|
|  | 141 |  | 
|---|
|  | 142 | #if !defined (_RL_FUNCTION_TYPEDEF) | 
|---|
|  | 143 | diff -Naur readline-6.3.orig/util.c readline-6.3/util.c | 
|---|
|  | 144 | --- readline-6.3.orig/util.c    2013-09-02 17:36:12.000000000 +0000 | 
|---|
|  | 145 | +++ readline-6.3/util.c 2014-09-27 00:01:42.949231680 +0000 | 
|---|
|  | 146 | @@ -476,6 +476,7 @@ | 
|---|
|  | 147 | return (strcpy ((char *)xmalloc (1 + (int)strlen (s)), (s))); | 
|---|
|  | 148 | } | 
|---|
|  | 149 |  | 
|---|
|  | 150 | +#if defined (DEBUG) | 
|---|
|  | 151 | #if defined (USE_VARARGS) | 
|---|
|  | 152 | static FILE *_rl_tracefp; | 
|---|
|  | 153 |  | 
|---|
|  | 154 | @@ -538,6 +539,7 @@ | 
|---|
|  | 155 | _rl_tracefp = fp; | 
|---|
|  | 156 | } | 
|---|
|  | 157 | #endif | 
|---|
|  | 158 | +#endif /* DEBUG */ | 
|---|
|  | 159 |  | 
|---|
|  | 160 |  | 
|---|
|  | 161 | #if HAVE_DECL_AUDIT_USER_TTY && defined (ENABLE_TTY_AUDIT_SUPPORT) | 
|---|