mirror of the now-defunct rocklinux.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

433 lines
12 KiB

  1. # --- ROCK-COPYRIGHT-NOTE-BEGIN ---
  2. #
  3. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  4. # Please add additional copyright information _after_ the line containing
  5. # the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by
  6. # the ./scripts/Create-CopyPatch script. Do not edit this copyright text!
  7. #
  8. # ROCK Linux: rock-src/package/base/bash/official-upto-007.patch
  9. # ROCK Linux is Copyright (C) 1998 - 2003 Clifford Wolf
  10. #
  11. # This program is free software; you can redistribute it and/or modify
  12. # it under the terms of the GNU General Public License as published by
  13. # the Free Software Foundation; either version 2 of the License, or
  14. # (at your option) any later version. A copy of the GNU General Public
  15. # License can be found at Documentation/COPYING.
  16. #
  17. # Many people helped and are helping developing ROCK Linux. Please
  18. # have a look at http://www.rocklinux.org/ and the Documentation/TEAM
  19. # file for details.
  20. #
  21. # --- ROCK-COPYRIGHT-NOTE-END ---
  22. Official patches from ftp://ftp.gnu.org/pub/gnu/bash/bash-2.05b-patches/.
  23. BASH PATCH REPORT
  24. =================
  25. Bash-Release: 2.05b
  26. Patch-ID: bash205b-001
  27. Bug-Reported-by: taviso@sdf.lonestar.org
  28. Bug-Reference-ID: <200208021107.g72B723d021352@darkstar.example.net>
  29. Bug-Reference-URL: http://mail.gnu.org/pipermail/bug-bash/2002-August/004980.html
  30. Bug-Description:
  31. Bash goes into an infinite loop and eventually crashes with a SIGSEGV
  32. when some keys on the numeric keypad are pressed, possibly in combination
  33. with the shift key.
  34. Patch:
  35. *** ./lib/readline/bind.c Thu Jan 24 11:15:52 2002
  36. --- ./lib/readline/bind.c Wed Jul 31 09:11:18 2002
  37. ***************
  38. *** 312,316 ****
  39. and the function bound to `a' to be executed when the user
  40. types `abx', leaving `bx' in the input queue. */
  41. ! if (k.function /* && k.type == ISFUNC */)
  42. {
  43. map[ANYOTHERKEY] = k;
  44. --- 312,316 ----
  45. and the function bound to `a' to be executed when the user
  46. types `abx', leaving `bx' in the input queue. */
  47. ! if (k.function && ((k.type == ISFUNC && k.function != rl_do_lowercase_version) || k.type == ISMACR))
  48. {
  49. map[ANYOTHERKEY] = k;
  50. BASH PATCH REPORT
  51. =================
  52. Bash-Release: 2.05b
  53. Patch-ID: bash205b-002
  54. Bug-Reported-by: rwhron@earthlink.net
  55. Bug-Reference-ID: <20020724000454.GA15210@rushmore> (bug-bash)
  56. Bug-Reference-URL: http://mail.gnu.org/pipermail/bug-bash/2002-July/004856.html
  57. Bug-Description:
  58. Repeating an edit in vi-mode with `.' does not work.
  59. Patch:
  60. *** ./lib/readline/readline.c Wed Mar 13 17:10:46 2002
  61. --- ./lib/readline/readline.c Tue Jul 30 17:46:44 2002
  62. ***************
  63. *** 685,688 ****
  64. --- 685,689 ----
  65. #if defined (VI_MODE)
  66. if (rl_editing_mode == vi_mode && _rl_keymap == vi_movement_keymap &&
  67. + key != ANYOTHERKEY &&
  68. _rl_vi_textmod_command (key))
  69. _rl_vi_set_last (key, rl_numeric_arg, rl_arg_sign);
  70. BASH PATCH REPORT
  71. =================
  72. Bash-Release: 2.05b
  73. Patch-ID: bash205b-003
  74. Bug-Reported-by: jan.q.bruun-andersen@posten.se
  75. Bug-Reference-ID: <BE156C6450189B4ABAF7381F0AD4724A0165674F@002exmbs002.ad.posten.se>
  76. Bug-Reference-URL: http://mail.gnu.org/pipermail/bug-bash/2002-July/004789.html
  77. Bug-Description:
  78. In certain cases, Bash appends a space instead of a slash to a directory
  79. name relative to the current directory when performing command name
  80. completion. This affects partial completion of intermediate directory
  81. names.
  82. Patch:
  83. *** ./bashline.c Tue May 7 15:52:42 2002
  84. --- ./bashline.c Sat Aug 3 11:40:16 2002
  85. ***************
  86. *** 1045,1049 ****
  87. --- 1045,1052 ----
  88. else
  89. {
  90. + #define CMD_IS_DIR(x) (absolute_pathname(x) == 0 && *(x) != '~' && test_for_directory (x))
  91. +
  92. matches = rl_completion_matches (text, command_word_completion_function);
  93. +
  94. /* If we are attempting command completion and nothing matches, we
  95. do not want readline to perform filename completion for us. We
  96. ***************
  97. *** 1053,1057 ****
  98. if (matches == (char **)NULL)
  99. rl_ignore_some_completions_function = bash_ignore_filenames;
  100. ! else if (matches[1] == 0 && *matches[0] != '/')
  101. /* Turn off rl_filename_completion_desired so readline doesn't
  102. append a slash if there is a directory with the same name
  103. --- 1056,1060 ----
  104. if (matches == (char **)NULL)
  105. rl_ignore_some_completions_function = bash_ignore_filenames;
  106. ! else if (matches[1] == 0 && CMD_IS_DIR(matches[0]))
  107. /* Turn off rl_filename_completion_desired so readline doesn't
  108. append a slash if there is a directory with the same name
  109. ***************
  110. *** 1062,1066 ****
  111. conflict. */
  112. rl_filename_completion_desired = 0;
  113. ! else if (matches[0] && matches[1] && STREQ (matches[0], matches[1]) && *matches[0] != '/')
  114. /* There are multiple instances of the same match (duplicate
  115. completions haven't yet been removed). In this case, all of
  116. --- 1065,1069 ----
  117. conflict. */
  118. rl_filename_completion_desired = 0;
  119. ! else if (matches[0] && matches[1] && STREQ (matches[0], matches[1]) && CMD_IS_DIR (matches[0]))
  120. /* There are multiple instances of the same match (duplicate
  121. completions haven't yet been removed). In this case, all of
  122. BASH PATCH REPORT
  123. =================
  124. Bash-Release: 2.05b
  125. Patch-ID: bash205b-004
  126. Bug-Reported-by: c.f.a.johnson@rogers.com
  127. Bug-Reference-ID: <aji8sb$1aa9bi$2@ID-136730.news.dfncis.de>
  128. Bug-Reference-URL: http://mail.gnu.org/pipermail/bug-bash/2002-August/005074.html
  129. Bug-Description:
  130. A bug in the bash variable expansion code causes leading blanks in a
  131. variable's value to be ignored when computing its length.
  132. Patch:
  133. *** ./subst.c Mon Jun 24 07:59:45 2002
  134. --- ./subst.c Sat Aug 17 17:28:46 2002
  135. ***************
  136. *** 1639,1647 ****
  137. /* This performs word splitting and quoted null character removal on
  138. STRING. */
  139. ! #if 0
  140. ! #define issep(c) ((separators)[1] ? (member ((c), separators)) : (c) == (separators)[0])
  141. ! #else
  142. ! #define issep(c) ((separators)[1] ? isifs(c) : (c) == (separators)[0])
  143. ! #endif
  144. WORD_LIST *
  145. --- 1639,1646 ----
  146. /* This performs word splitting and quoted null character removal on
  147. STRING. */
  148. ! #define issep(c) \
  149. ! (((separators)[0]) ? ((separators)[1] ? isifs(c) \
  150. ! : (c) == (separators)[0]) \
  151. ! : 0)
  152. WORD_LIST *
  153. BASH PATCH REPORT
  154. =================
  155. Bash-Release: 2.05b
  156. Patch-ID: bash205b-005
  157. Bug-Reported-by: Jim Meyering <jim@meyering.net>
  158. Bug-Reference-ID: <87bs6v8iib.fsf@pixie.eng.ascend.com>
  159. Bug-Reference-URL: http://mail.gnu.org/archive/html/bug-bash/2002-09/msg00047.html
  160. Bug-Description:
  161. When in a locale with multibyte characters, the readline display updater
  162. will occasionally cause a segmentation fault when attempting to compute
  163. the length of the first multibyte character on the line.
  164. Patch:
  165. *** ./lib/readline/mbutil.c Tue Jun 4 11:54:29 2002
  166. --- ./lib/readline/mbutil.c Mon Aug 5 11:20:39 2002
  167. ***************
  168. *** 206,210 ****
  169. {
  170. /* shorted to compose multibyte char */
  171. ! memset (ps, 0, sizeof(mbstate_t));
  172. return -2;
  173. }
  174. --- 206,211 ----
  175. {
  176. /* shorted to compose multibyte char */
  177. ! if (ps)
  178. ! memset (ps, 0, sizeof(mbstate_t));
  179. return -2;
  180. }
  181. ***************
  182. *** 213,217 ****
  183. /* invalid to compose multibyte char */
  184. /* initialize the conversion state */
  185. ! memset (ps, 0, sizeof(mbstate_t));
  186. return -1;
  187. }
  188. --- 214,219 ----
  189. /* invalid to compose multibyte char */
  190. /* initialize the conversion state */
  191. ! if (ps)
  192. ! memset (ps, 0, sizeof(mbstate_t));
  193. return -1;
  194. }
  195. ***************
  196. *** 226,232 ****
  197. int
  198. _rl_compare_chars (buf1, pos1, ps1, buf2, pos2, ps2)
  199. ! char *buf1, *buf2;
  200. ! mbstate_t *ps1, *ps2;
  201. ! int pos1, pos2;
  202. {
  203. int i, w1, w2;
  204. --- 228,237 ----
  205. int
  206. _rl_compare_chars (buf1, pos1, ps1, buf2, pos2, ps2)
  207. ! char *buf1;
  208. ! int pos1;
  209. ! mbstate_t *ps1;
  210. ! char *buf2;
  211. ! int pos2;
  212. ! mbstate_t *ps2;
  213. {
  214. int i, w1, w2;
  215. ***************
  216. *** 277,282 ****
  217. /* clear the state of the byte sequence, because
  218. in this case effect of mbstate is undefined */
  219. ! memset (ps, 0, sizeof (mbstate_t));
  220. }
  221. else
  222. pos += tmp;
  223. --- 282,290 ----
  224. /* clear the state of the byte sequence, because
  225. in this case effect of mbstate is undefined */
  226. ! if (ps)
  227. ! memset (ps, 0, sizeof (mbstate_t));
  228. }
  229. + else if (tmp == 0)
  230. + pos++;
  231. else
  232. pos += tmp;
  233. BASH PATCH REPORT
  234. =================
  235. Bash-Release: 2.05b
  236. Patch-ID: bash205b-006
  237. Bug-Reported-by: clowenst@ucsd.edu
  238. Bug-Reference-ID: <156388ec.0212021151.51a48df1@posting.google.com>
  239. Bug-Reference-URL:
  240. Bug-Description:
  241. When running in a locale with multibyte characters, the readline display
  242. updater will use carriage returns when drawing the line, overwriting any
  243. partial output already on the screen and not terminated by a newline.
  244. Patch:
  245. *** ./lib/readline/display.c Tue Jun 4 10:54:47 2002
  246. --- ./lib/readline/display.c Fri Sep 13 16:22:57 2002
  247. ***************
  248. *** 71,75 ****
  249. #if defined (HANDLE_MULTIBYTE)
  250. ! static int _rl_col_width PARAMS((char *, int, int));
  251. static int *_rl_wrapped_line;
  252. #else
  253. --- 71,75 ----
  254. #if defined (HANDLE_MULTIBYTE)
  255. ! static int _rl_col_width PARAMS((const char *, int, int));
  256. static int *_rl_wrapped_line;
  257. #else
  258. ***************
  259. *** 1349,1355 ****
  260. _rl_output_some_chars (nfd + lendiff, temp - lendiff);
  261. #if 0
  262. - _rl_last_c_pos += _rl_col_width (nfd+lendiff, 0, temp-lendiff) - col_lendiff;
  263. - #else
  264. _rl_last_c_pos += _rl_col_width (nfd+lendiff, 0, temp-col_lendiff);
  265. #endif
  266. }
  267. --- 1349,1355 ----
  268. _rl_output_some_chars (nfd + lendiff, temp - lendiff);
  269. #if 0
  270. _rl_last_c_pos += _rl_col_width (nfd+lendiff, 0, temp-col_lendiff);
  271. + #else
  272. + _rl_last_c_pos += _rl_col_width (nfd+lendiff, 0, temp-lendiff);
  273. #endif
  274. }
  275. ***************
  276. *** 1511,1516 ****
  277. /* If we have multibyte characters, NEW is indexed by the buffer point in
  278. a multibyte string, but _rl_last_c_pos is the display position. In
  279. ! this case, NEW's display position is not obvious. */
  280. ! if ((MB_CUR_MAX == 1 || rl_byte_oriented ) && _rl_last_c_pos == new) return;
  281. #else
  282. if (_rl_last_c_pos == new) return;
  283. --- 1511,1523 ----
  284. /* If we have multibyte characters, NEW is indexed by the buffer point in
  285. a multibyte string, but _rl_last_c_pos is the display position. In
  286. ! this case, NEW's display position is not obvious and must be
  287. ! calculated. */
  288. ! if (MB_CUR_MAX == 1 || rl_byte_oriented)
  289. ! {
  290. ! if (_rl_last_c_pos == new)
  291. ! return;
  292. ! }
  293. ! else if (_rl_last_c_pos == _rl_col_width (data, 0, new))
  294. ! return;
  295. #else
  296. if (_rl_last_c_pos == new) return;
  297. ***************
  298. *** 1595,1603 ****
  299. {
  300. if (MB_CUR_MAX > 1 && rl_byte_oriented == 0)
  301. ! {
  302. ! tputs (_rl_term_cr, 1, _rl_output_character_function);
  303. ! for (i = 0; i < new; i++)
  304. ! putc (data[i], rl_outstream);
  305. ! }
  306. else
  307. _rl_backspace (_rl_last_c_pos - new);
  308. --- 1602,1606 ----
  309. {
  310. if (MB_CUR_MAX > 1 && rl_byte_oriented == 0)
  311. ! _rl_backspace (_rl_last_c_pos - _rl_col_width (data, 0, new));
  312. else
  313. _rl_backspace (_rl_last_c_pos - new);
  314. ***************
  315. *** 2118,2122 ****
  316. static int
  317. _rl_col_width (str, start, end)
  318. ! char *str;
  319. int start, end;
  320. {
  321. --- 2121,2125 ----
  322. static int
  323. _rl_col_width (str, start, end)
  324. ! const char *str;
  325. int start, end;
  326. {
  327. ***************
  328. *** 2194,2196 ****
  329. }
  330. #endif /* HANDLE_MULTIBYTE */
  331. -
  332. --- 2197,2198 ----
  333. BASH PATCH REPORT
  334. =================
  335. Bash-Release: 2.05b
  336. Patch-ID: bash205b-007
  337. Bug-Reported-by: dman@dman.ddts.net
  338. Bug-Reference-ID: <15893.26358.129589.503364@gargle.gargle.HOWL>
  339. Bug-Reference-URL: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=175127
  340. Bug-Description:
  341. Using the vi editing mode's case-changing commands in a locale with
  342. multibyte characters will cause garbage characters to be inserted into
  343. the editing buffer.
  344. Patch:
  345. *** ./lib/readline/vi_mode.c Thu May 23 13:27:58 2002
  346. --- ./lib/readline/vi_mode.c Tue Feb 4 15:11:07 2003
  347. ***************
  348. *** 681,685 ****
  349. {
  350. wchar_t wc;
  351. ! char mb[MB_LEN_MAX];
  352. mbstate_t ps;
  353. --- 681,686 ----
  354. {
  355. wchar_t wc;
  356. ! char mb[MB_LEN_MAX+1];
  357. ! int mblen;
  358. mbstate_t ps;
  359. ***************
  360. *** 704,708 ****
  361. if (wc)
  362. {
  363. ! wctomb (mb, wc);
  364. rl_begin_undo_group ();
  365. rl_delete (1, 0);
  366. --- 705,711 ----
  367. if (wc)
  368. {
  369. ! mblen = wctomb (mb, wc);
  370. ! if (mblen >= 0)
  371. ! mb[mblen] = '\0';
  372. rl_begin_undo_group ();
  373. rl_delete (1, 0);