Changeset e92465d for patches/bash-4.0-branch_update-7.patch
- Timestamp:
- Sep 13, 2009, 8:25:05 PM (15 years ago)
- Branches:
- clfs-1.2, clfs-2.1, clfs-3.0.0-systemd, clfs-3.0.0-sysvinit, master, systemd, sysvinit
- Children:
- 0a81d23
- Parents:
- dca5b7b (diff), 32cb8ca (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
patches/bash-4.0-branch_update-7.patch
rdca5b7b re92465d 1 1 Submitted By: Jim Gifford (jim at cross-lfs dot org) 2 Date: 0 7-22-20092 Date: 09-12-2009 3 3 Initial Package Version: 4.0 4 4 Origin: Upstream 5 5 Upstream Status: Applied 6 Description: Contains all upstream patches up to 4.0-0 286 Description: Contains all upstream patches up to 4.0-033 7 7 8 8 diff -Naur bash-4.0.orig/arrayfunc.c bash-4.0/arrayfunc.c 9 9 --- bash-4.0.orig/arrayfunc.c 2009-01-04 11:32:21.000000000 -0800 10 +++ bash-4.0/arrayfunc.c 2009-07-22 15:31:16.000000000 -0700 10 +++ bash-4.0/arrayfunc.c 2009-09-12 08:23:47.000000000 -0700 11 @@ -98,7 +98,7 @@ 12 oldval = value_cell (var); 13 hash = assoc_create (0); 14 if (oldval) 15 - assoc_insert (hash, "0", oldval); 16 + assoc_insert (hash, savestring ("0"), oldval); 17 18 FREE (value_cell (var)); 19 var_setassoc (var, hash); 11 20 @@ -604,64 +604,7 @@ 12 21 } … … 75 84 /* This function is called with SUB pointing to just after the beginning 76 85 `[' of an array subscript and removes the array element to which SUB 86 diff -Naur bash-4.0.orig/bashline.c bash-4.0/bashline.c 87 --- bash-4.0.orig/bashline.c 2009-01-08 06:29:24.000000000 -0800 88 +++ bash-4.0/bashline.c 2009-09-12 08:23:46.000000000 -0700 89 @@ -3388,7 +3388,6 @@ 90 Keymap xkmap; /* unix command executing keymap */ 91 register int i; 92 intmax_t mi; 93 - int save_point; 94 sh_parser_state_t ps; 95 char *cmd, *value, *l; 96 SHELL_VAR *v; 97 @@ -3432,7 +3431,6 @@ 98 if (v) 99 VSETATTR (v, att_exported); 100 l = value_cell (v); 101 - save_point = rl_point; 102 value = inttostr (rl_point, ibuf, sizeof (ibuf)); 103 v = bind_int_variable ("READLINE_POINT", value); 104 if (v) 105 @@ -3450,7 +3448,7 @@ 106 if (v && legal_number (value_cell (v), &mi)) 107 { 108 i = mi; 109 - if (i != save_point) 110 + if (i != rl_point) 111 { 112 rl_point = i; 113 if (rl_point > rl_end) 77 114 diff -Naur bash-4.0.orig/builtins/declare.def bash-4.0/builtins/declare.def 78 115 --- bash-4.0.orig/builtins/declare.def 2009-01-04 11:32:22.000000000 -0800 79 +++ bash-4.0/builtins/declare.def 2009-0 7-22 15:31:12.000000000 -0700116 +++ bash-4.0/builtins/declare.def 2009-09-12 08:23:07.000000000 -0700 80 117 @@ -295,6 +295,13 @@ 81 118 subscript_start = (char *)NULL; … … 103 140 diff -Naur bash-4.0.orig/builtins/exit.def bash-4.0/builtins/exit.def 104 141 --- bash-4.0.orig/builtins/exit.def 2009-01-04 11:32:22.000000000 -0800 105 +++ bash-4.0/builtins/exit.def 2009-0 7-22 15:31:11.000000000 -0700142 +++ bash-4.0/builtins/exit.def 2009-09-12 08:23:05.000000000 -0700 106 143 @@ -113,7 +113,7 @@ 107 144 for (i = stopmsg = 0; i < js.j_jobslots; i++) … … 115 152 diff -Naur bash-4.0.orig/builtins/fc.def bash-4.0/builtins/fc.def 116 153 --- bash-4.0.orig/builtins/fc.def 2009-01-04 11:32:22.000000000 -0800 117 +++ bash-4.0/builtins/fc.def 2009-0 7-22 15:31:26.000000000 -0700154 +++ bash-4.0/builtins/fc.def 2009-09-12 08:23:21.000000000 -0700 118 155 @@ -88,6 +88,7 @@ 119 156 extern int current_command_line_count; … … 181 218 diff -Naur bash-4.0.orig/builtins/read.def bash-4.0/builtins/read.def 182 219 --- bash-4.0.orig/builtins/read.def 2009-01-15 20:11:21.000000000 -0800 183 +++ bash-4.0/builtins/read.def 2009-0 7-22 15:31:19.000000000 -0700220 +++ bash-4.0/builtins/read.def 2009-09-12 08:23:50.000000000 -0700 184 221 @@ -369,14 +369,14 @@ 185 222 code = setjmp (alrmbuf); … … 202 239 old_alrm = set_signal_handler (SIGALRM, sigalrm); 203 240 add_unwind_protect (reset_alarm, (char *)NULL); 241 @@ -763,7 +763,10 @@ 242 if (*input_string == 0) 243 tofree = input_string = t; 244 else 245 - input_string = strip_trailing_ifs_whitespace (t1, ifs_chars, saw_escape); 246 + { 247 + input_string = strip_trailing_ifs_whitespace (t1, ifs_chars, saw_escape); 248 + tofree = t; 249 + } 250 } 251 #endif 252 204 253 diff -Naur bash-4.0.orig/doc/bash.1 bash-4.0/doc/bash.1 205 254 --- bash-4.0.orig/doc/bash.1 2009-02-18 12:13:56.000000000 -0800 206 +++ bash-4.0/doc/bash.1 2009-0 7-22 15:31:48.000000000 -0700255 +++ bash-4.0/doc/bash.1 2009-09-12 08:23:43.000000000 -0700 207 256 @@ -8257,9 +8257,10 @@ 208 257 Exit after reading and executing one command. … … 220 269 diff -Naur bash-4.0.orig/doc/bashref.texi bash-4.0/doc/bashref.texi 221 270 --- bash-4.0.orig/doc/bashref.texi 2009-02-18 12:14:43.000000000 -0800 222 +++ bash-4.0/doc/bashref.texi 2009-0 7-22 15:31:48.000000000 -0700271 +++ bash-4.0/doc/bashref.texi 2009-09-12 08:23:43.000000000 -0700 223 272 @@ -4138,7 +4138,8 @@ 224 273 Exit after reading and executing one command. … … 233 282 diff -Naur bash-4.0.orig/execute_cmd.c bash-4.0/execute_cmd.c 234 283 --- bash-4.0.orig/execute_cmd.c 2009-02-13 13:41:41.000000000 -0800 235 +++ bash-4.0/execute_cmd.c 2009-0 7-22 15:31:29.000000000 -0700284 +++ bash-4.0/execute_cmd.c 2009-09-12 08:23:24.000000000 -0700 236 285 @@ -568,6 +568,7 @@ 237 286 … … 299 348 diff -Naur bash-4.0.orig/externs.h bash-4.0/externs.h 300 349 --- bash-4.0.orig/externs.h 2009-01-18 15:29:29.000000000 -0800 301 +++ bash-4.0/externs.h 2009-0 7-22 15:31:45.000000000 -0700350 +++ bash-4.0/externs.h 2009-09-12 08:23:39.000000000 -0700 302 351 @@ -192,6 +192,8 @@ 303 352 extern char *fmtumax __P((uintmax_t, int, char *, size_t, int)); … … 320 369 diff -Naur bash-4.0.orig/jobs.c bash-4.0/jobs.c 321 370 --- bash-4.0.orig/jobs.c 2009-01-29 14:09:49.000000000 -0800 322 +++ bash-4.0/jobs.c 2009-0 7-22 15:31:34.000000000 -0700371 +++ bash-4.0/jobs.c 2009-09-12 08:23:29.000000000 -0700 323 372 @@ -442,7 +442,7 @@ 324 373 old_pipeline = the_pipeline; … … 356 405 diff -Naur bash-4.0.orig/jobs.h bash-4.0/jobs.h 357 406 --- bash-4.0.orig/jobs.h 2009-01-04 11:32:29.000000000 -0800 358 +++ bash-4.0/jobs.h 2009-0 7-22 15:31:34.000000000 -0700407 +++ bash-4.0/jobs.h 2009-09-12 08:23:29.000000000 -0700 359 408 @@ -235,6 +235,8 @@ 360 409 extern void init_job_stats __P((void)); … … 368 417 diff -Naur bash-4.0.orig/lib/glob/glob.c bash-4.0/lib/glob/glob.c 369 418 --- bash-4.0.orig/lib/glob/glob.c 2009-01-04 11:32:30.000000000 -0800 370 +++ bash-4.0/lib/glob/glob.c 2009-0 7-22 15:31:43.000000000 -0700419 +++ bash-4.0/lib/glob/glob.c 2009-09-12 08:23:38.000000000 -0700 371 420 @@ -356,7 +356,7 @@ 372 421 *np = 0; … … 441 490 diff -Naur bash-4.0.orig/lib/readline/display.c bash-4.0/lib/readline/display.c 442 491 --- bash-4.0.orig/lib/readline/display.c 2009-01-04 11:32:32.000000000 -0800 443 +++ bash-4.0/lib/readline/display.c 2009-0 7-22 15:31:46.000000000 -0700492 +++ bash-4.0/lib/readline/display.c 2009-09-12 08:23:41.000000000 -0700 444 493 @@ -512,6 +512,7 @@ 445 494 /* Block keyboard interrupts because this function manipulates global … … 519 568 diff -Naur bash-4.0.orig/lib/readline/readline.h bash-4.0/lib/readline/readline.h 520 569 --- bash-4.0.orig/lib/readline/readline.h 2009-01-04 11:32:33.000000000 -0800 521 +++ bash-4.0/lib/readline/readline.h 2009-0 7-22 15:31:36.000000000 -0700570 +++ bash-4.0/lib/readline/readline.h 2009-09-12 08:23:30.000000000 -0700 522 571 @@ -814,8 +814,9 @@ 523 572 #define RL_STATE_VIMOTION 0x100000 /* reading vi motion arg */ … … 533 582 diff -Naur bash-4.0.orig/lib/readline/terminal.c bash-4.0/lib/readline/terminal.c 534 583 --- bash-4.0.orig/lib/readline/terminal.c 2009-01-04 11:32:34.000000000 -0800 535 +++ bash-4.0/lib/readline/terminal.c 2009-0 7-22 15:31:36.000000000 -0700584 +++ bash-4.0/lib/readline/terminal.c 2009-09-12 08:23:30.000000000 -0700 536 585 @@ -355,7 +355,7 @@ 537 586 _rl_get_screen_size (fileno (rl_instream), 1); … … 545 594 diff -Naur bash-4.0.orig/lib/sh/winsize.c bash-4.0/lib/sh/winsize.c 546 595 --- bash-4.0.orig/lib/sh/winsize.c 2008-08-12 10:53:51.000000000 -0700 547 +++ bash-4.0/lib/sh/winsize.c 2009-0 7-22 15:31:33.000000000 -0700596 +++ bash-4.0/lib/sh/winsize.c 2009-09-12 08:23:27.000000000 -0700 548 597 @@ -30,16 +30,29 @@ 549 598 … … 587 636 diff -Naur bash-4.0.orig/parse.y bash-4.0/parse.y 588 637 --- bash-4.0.orig/parse.y 2009-01-08 05:29:12.000000000 -0800 589 +++ bash-4.0/parse.y 2009-0 7-22 15:31:39.000000000 -0700638 +++ bash-4.0/parse.y 2009-09-12 08:23:33.000000000 -0700 590 639 @@ -1122,7 +1122,7 @@ 591 640 REDIRECTEE rd; … … 833 882 diff -Naur bash-4.0.orig/patchlevel.h bash-4.0/patchlevel.h 834 883 --- bash-4.0.orig/patchlevel.h 2009-01-04 11:32:40.000000000 -0800 835 +++ bash-4.0/patchlevel.h 2009-0 7-22 15:31:48.000000000 -0700884 +++ bash-4.0/patchlevel.h 2009-09-12 08:23:50.000000000 -0700 836 885 @@ -25,6 +25,6 @@ 837 886 regexp `^#define[ ]*PATCHLEVEL', since that's what support/mkversion.sh … … 839 888 840 889 -#define PATCHLEVEL 0 841 +#define PATCHLEVEL 28890 +#define PATCHLEVEL 33 842 891 843 892 #endif /* _PATCHLEVEL_H_ */ 844 893 diff -Naur bash-4.0.orig/pcomplete.c bash-4.0/pcomplete.c 845 894 --- bash-4.0.orig/pcomplete.c 2009-02-01 14:12:31.000000000 -0800 846 +++ bash-4.0/pcomplete.c 2009-0 7-22 15:31:08.000000000 -0700895 +++ bash-4.0/pcomplete.c 2009-09-12 08:23:02.000000000 -0700 847 896 @@ -1032,6 +1032,7 @@ 848 897 cmdlist = build_arg_list (funcname, text, lwords, cw); … … 855 904 diff -Naur bash-4.0.orig/sig.c bash-4.0/sig.c 856 905 --- bash-4.0.orig/sig.c 2009-01-04 11:32:41.000000000 -0800 857 +++ bash-4.0/sig.c 2009-0 7-22 15:31:28.000000000 -0700906 +++ bash-4.0/sig.c 2009-09-12 08:23:22.000000000 -0700 858 907 @@ -448,6 +448,48 @@ 859 908 termsig_sighandler (sig) … … 907 956 diff -Naur bash-4.0.orig/subst.c bash-4.0/subst.c 908 957 --- bash-4.0.orig/subst.c 2009-01-28 11:34:12.000000000 -0800 909 +++ bash-4.0/subst.c 2009-0 7-22 15:31:48.000000000 -0700958 +++ bash-4.0/subst.c 2009-09-12 08:23:49.000000000 -0700 910 959 @@ -85,6 +85,7 @@ 911 960 … … 1080 1129 1081 1130 return w; 1131 @@ -6503,7 +6606,7 @@ 1132 *contains_dollar_at = 1; 1133 } 1134 free (x); 1135 - free (xlist); 1136 + dispose_words (xlist); 1137 free (temp1); 1138 *indexp = sindex; 1139 1082 1140 @@ -6556,7 +6659,7 @@ 1083 1141 if (want_indir) … … 1163 1221 diff -Naur bash-4.0.orig/trap.c bash-4.0/trap.c 1164 1222 --- bash-4.0.orig/trap.c 2009-01-16 14:07:53.000000000 -0800 1165 +++ bash-4.0/trap.c 2009-0 7-22 15:31:34.000000000 -07001223 +++ bash-4.0/trap.c 2009-09-12 08:23:29.000000000 -0700 1166 1224 @@ -755,7 +755,7 @@ 1167 1225 } … … 1210 1268 #if defined (DEBUGGER) 1211 1269 /* If we're in the debugger and the DEBUG trap returns 2 while we're in 1270 diff -Naur bash-4.0.orig/variables.c bash-4.0/variables.c 1271 --- bash-4.0.orig/variables.c 2009-01-04 11:32:46.000000000 -0800 1272 +++ bash-4.0/variables.c 2009-09-12 08:23:47.000000000 -0700 1273 @@ -252,6 +252,7 @@ 1274 1275 static int visible_var __P((SHELL_VAR *)); 1276 static int visible_and_exported __P((SHELL_VAR *)); 1277 +static int export_environment_candidate __P((SHELL_VAR *)); 1278 static int local_and_exported __P((SHELL_VAR *)); 1279 static int variable_in_context __P((SHELL_VAR *)); 1280 #if defined (ARRAY_VARS) 1281 @@ -375,10 +376,17 @@ 1282 } 1283 # endif 1284 #endif 1285 +#if 0 1286 else if (legal_identifier (name)) 1287 +#else 1288 + else 1289 +#endif 1290 { 1291 temp_var = bind_variable (name, string, 0); 1292 - VSETATTR (temp_var, (att_exported | att_imported)); 1293 + if (legal_identifier (name)) 1294 + VSETATTR (temp_var, (att_exported | att_imported)); 1295 + else 1296 + VSETATTR (temp_var, (att_exported | att_imported | att_invisible)); 1297 array_needs_making = 1; 1298 } 1299 1300 @@ -2209,7 +2217,7 @@ 1301 } 1302 else if (assoc_p (entry)) 1303 { 1304 - assoc_insert (assoc_cell (entry), "0", newval); 1305 + assoc_insert (assoc_cell (entry), savestring ("0"), newval); 1306 free (newval); 1307 } 1308 else 1309 @@ -3082,6 +3090,16 @@ 1310 return (invisible_p (var) == 0 && exported_p (var)); 1311 } 1312 1313 +/* Candidate variables for the export environment are either valid variables 1314 + with the export attribute or invalid variables inherited from the initial 1315 + environment and simply passed through. */ 1316 +static int 1317 +export_environment_candidate (var) 1318 + SHELL_VAR *var; 1319 +{ 1320 + return (exported_p (var) && (invisible_p (var) == 0 || imported_p (var))); 1321 +} 1322 + 1323 /* Return non-zero if VAR is a local variable in the current context and 1324 is exported. */ 1325 static int 1326 @@ -3438,7 +3456,11 @@ 1327 char **list; 1328 SHELL_VAR **vars; 1329 1330 +#if 0 1331 vars = map_over (visible_and_exported, vcxt); 1332 +#else 1333 + vars = map_over (export_environment_candidate, vcxt); 1334 +#endif 1335 1336 if (vars == 0) 1337 return (char **)NULL;
Note:
See TracChangeset
for help on using the changeset viewer.