wok-6.x diff readline/stuff/readline-6.3-upstream_fixes-3.patch @ rev 20694

get-palemoon: update wget_url
author Richard Dunbar <mojo@slitaz.org>
date Mon Feb 04 01:44:39 2019 -0500 (2019-02-04)
parents
children
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/readline/stuff/readline-6.3-upstream_fixes-3.patch	Mon Feb 04 01:44:39 2019 -0500
     1.3 @@ -0,0 +1,155 @@
     1.4 +Submitted By:            Bruce Dubbs <bdubbs_at_linuxfromscratch_dot_org>
     1.5 +Updated By:              Armin K. <krejzi at email dot com>
     1.6 +Date:                    2014-10-04
     1.7 +Initial Package Version: 6.3
     1.8 +Upstream Status:         Already in upstream patch repo
     1.9 +Origin:                  Upstream
    1.10 +Description:             This patch contains upstream patch numbers 001 through 008.
    1.11 +
    1.12 +--- a/display.c	2013-12-27 19:10:56.000000000 +0100
    1.13 ++++ b/display.c	2014-10-04 21:30:27.039621661 +0200
    1.14 +@@ -1637,7 +1637,7 @@
    1.15 +   /* If we are changing the number of invisible characters in a line, and
    1.16 +      the spot of first difference is before the end of the invisible chars,
    1.17 +      lendiff needs to be adjusted. */
    1.18 +-  if (current_line == 0 && !_rl_horizontal_scroll_mode &&
    1.19 ++  if (current_line == 0 && /* !_rl_horizontal_scroll_mode && */
    1.20 +       current_invis_chars != visible_wrap_offset)
    1.21 +     {
    1.22 +       if (MB_CUR_MAX > 1 && rl_byte_oriented == 0)
    1.23 +@@ -1825,8 +1825,13 @@
    1.24 + 	      else
    1.25 + 		_rl_last_c_pos += bytes_to_insert;
    1.26 + 
    1.27 ++	      /* XXX - we only want to do this if we are at the end of the line
    1.28 ++		 so we move there with _rl_move_cursor_relative */
    1.29 + 	      if (_rl_horizontal_scroll_mode && ((oe-old) > (ne-new)))
    1.30 +-		goto clear_rest_of_line;
    1.31 ++		{
    1.32 ++		  _rl_move_cursor_relative (ne-new, new);
    1.33 ++		  goto clear_rest_of_line;
    1.34 ++		}
    1.35 + 	    }
    1.36 + 	}
    1.37 +       /* Otherwise, print over the existing material. */
    1.38 +@@ -2677,7 +2682,8 @@
    1.39 + {
    1.40 +   if (_rl_echoing_p)
    1.41 +     {
    1.42 +-      _rl_move_vert (_rl_vis_botlin);
    1.43 ++      if (_rl_vis_botlin > 0)	/* minor optimization plus bug fix */
    1.44 ++	_rl_move_vert (_rl_vis_botlin);
    1.45 +       _rl_vis_botlin = 0;
    1.46 +       fflush (rl_outstream);
    1.47 +       rl_restart_output (1, 0);
    1.48 +--- a/input.c	2014-01-10 21:07:08.000000000 +0100
    1.49 ++++ b/input.c	2014-10-04 21:30:27.347630462 +0200
    1.50 +@@ -534,8 +534,16 @@
    1.51 + 	return (RL_ISSTATE (RL_STATE_READCMD) ? READERR : EOF);
    1.52 +       else if (_rl_caught_signal == SIGHUP || _rl_caught_signal == SIGTERM)
    1.53 + 	return (RL_ISSTATE (RL_STATE_READCMD) ? READERR : EOF);
    1.54 ++      /* keyboard-generated signals of interest */
    1.55 +       else if (_rl_caught_signal == SIGINT || _rl_caught_signal == SIGQUIT)
    1.56 +         RL_CHECK_SIGNALS ();
    1.57 ++      /* non-keyboard-generated signals of interest */
    1.58 ++      else if (_rl_caught_signal == SIGALRM
    1.59 ++#if defined (SIGVTALRM)
    1.60 ++		|| _rl_caught_signal == SIGVTALRM
    1.61 ++#endif
    1.62 ++	      )
    1.63 ++        RL_CHECK_SIGNALS ();
    1.64 + 
    1.65 +       if (rl_signal_event_hook)
    1.66 + 	(*rl_signal_event_hook) ();
    1.67 +--- a/misc.c	2012-09-02 00:03:11.000000000 +0200
    1.68 ++++ b/misc.c	2014-10-04 21:30:27.625638402 +0200
    1.69 +@@ -461,6 +461,7 @@
    1.70 + 	    saved_undo_list = 0;
    1.71 + 	  /* Set up rl_line_buffer and other variables from history entry */
    1.72 + 	  rl_replace_from_history (entry, 0);	/* entry->line is now current */
    1.73 ++	  entry->data = 0;			/* entry->data is now current undo list */
    1.74 + 	  /* Undo all changes to this history entry */
    1.75 + 	  while (rl_undo_list)
    1.76 + 	    rl_do_undo ();
    1.77 +@@ -468,7 +469,6 @@
    1.78 + 	     the timestamp. */
    1.79 + 	  FREE (entry->line);
    1.80 + 	  entry->line = savestring (rl_line_buffer);
    1.81 +-	  entry->data = 0;
    1.82 + 	}
    1.83 +       entry = previous_history ();
    1.84 +     }
    1.85 +--- a/patchlevel	2013-11-15 14:11:11.000000000 +0100
    1.86 ++++ b/patchlevel	2014-10-04 21:30:27.625638402 +0200
    1.87 +@@ -1,3 +1,3 @@
    1.88 + # Do not edit -- exists only for use by patch
    1.89 + 
    1.90 +-5
    1.91 ++8
    1.92 +--- a/readline.c	2013-10-28 19:58:06.000000000 +0100
    1.93 ++++ b/readline.c	2014-10-04 21:30:25.951590557 +0200
    1.94 +@@ -744,7 +744,8 @@
    1.95 +     r = _rl_subseq_result (r, cxt->oldmap, cxt->okey, (cxt->flags & KSEQ_SUBSEQ));
    1.96 + 
    1.97 +   RL_CHECK_SIGNALS ();
    1.98 +-  if (r == 0)			/* success! */
    1.99 ++  /* We only treat values < 0 specially to simulate recursion. */
   1.100 ++  if (r >= 0 || (r == -1 && (cxt->flags & KSEQ_SUBSEQ) == 0))	/* success! or failure! */
   1.101 +     {
   1.102 +       _rl_keyseq_chain_dispose ();
   1.103 +       RL_UNSETSTATE (RL_STATE_MULTIKEY);
   1.104 +@@ -964,7 +965,7 @@
   1.105 + #if defined (VI_MODE)
   1.106 +   if (rl_editing_mode == vi_mode && _rl_keymap == vi_movement_keymap &&
   1.107 +       key != ANYOTHERKEY &&
   1.108 +-      rl_key_sequence_length == 1 &&	/* XXX */
   1.109 ++      _rl_dispatching_keymap == vi_movement_keymap &&
   1.110 +       _rl_vi_textmod_command (key))
   1.111 +     _rl_vi_set_last (key, rl_numeric_arg, rl_arg_sign);
   1.112 + #endif
   1.113 +--- a/rltypedefs.h	2011-03-26 19:53:31.000000000 +0100
   1.114 ++++ b/rltypedefs.h	2014-10-04 21:30:26.747613312 +0200
   1.115 +@@ -26,6 +26,25 @@
   1.116 + extern "C" {
   1.117 + #endif
   1.118 + 
   1.119 ++/* Old-style, attempt to mark as deprecated in some way people will notice. */
   1.120 ++
   1.121 ++#if !defined (_FUNCTION_DEF)
   1.122 ++#  define _FUNCTION_DEF
   1.123 ++
   1.124 ++#if defined(__GNUC__) || defined(__clang__)
   1.125 ++typedef int Function () __attribute__ ((deprecated));
   1.126 ++typedef void VFunction () __attribute__ ((deprecated));
   1.127 ++typedef char *CPFunction () __attribute__ ((deprecated));
   1.128 ++typedef char **CPPFunction () __attribute__ ((deprecated));
   1.129 ++#else
   1.130 ++typedef int Function ();
   1.131 ++typedef void VFunction ();
   1.132 ++typedef char *CPFunction ();
   1.133 ++typedef char **CPPFunction ();
   1.134 ++#endif
   1.135 ++
   1.136 ++#endif /* _FUNCTION_DEF */
   1.137 ++
   1.138 + /* New style. */
   1.139 + 
   1.140 + #if !defined (_RL_FUNCTION_TYPEDEF)
   1.141 +--- a/util.c	2013-09-02 19:36:12.000000000 +0200
   1.142 ++++ b/util.c	2014-10-04 21:30:26.206597848 +0200
   1.143 +@@ -476,6 +476,7 @@
   1.144 +   return (strcpy ((char *)xmalloc (1 + (int)strlen (s)), (s)));
   1.145 + }
   1.146 + 
   1.147 ++#if defined (DEBUG)
   1.148 + #if defined (USE_VARARGS)
   1.149 + static FILE *_rl_tracefp;
   1.150 + 
   1.151 +@@ -538,6 +539,7 @@
   1.152 +   _rl_tracefp = fp;
   1.153 + }
   1.154 + #endif
   1.155 ++#endif /* DEBUG */
   1.156 + 
   1.157 + 
   1.158 + #if HAVE_DECL_AUDIT_USER_TTY && defined (ENABLE_TTY_AUDIT_SUPPORT)