author | Rich Burridge <rich.burridge@oracle.com> |
Mon, 01 Feb 2016 12:51:27 -0800 | |
changeset 5377 | 36d18b39fc39 |
parent 1275 | 03b86a2f9021 |
permissions | -rw-r--r-- |
1275
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
1 |
BASH PATCH REPORT |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
2 |
================= |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
3 |
|
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
4 |
Bash-Release: 4.2 |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
5 |
Patch-ID: bash42-045 |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
6 |
|
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
7 |
Bug-Reported-by: Stephane Chazelas <[email protected]> |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
8 |
Bug-Reference-ID: <[email protected]> |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
9 |
Bug-Reference-URL: http://lists.gnu.org/archive/html/bug-bash/2013-02/msg00080.html |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
10 |
|
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
11 |
Bug-Description: |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
12 |
|
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
13 |
The <&n- and >&n- redirections, which move one file descriptor to another, |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
14 |
leave the file descriptor closed when applied to builtins or compound |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
15 |
commands. |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
16 |
|
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
17 |
Patch (apply with `patch -p0'): |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
18 |
|
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
19 |
*** ../bash-4.2-patched/redir.c 2013-01-30 11:56:09.000000000 -0500 |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
20 |
--- redir.c 2013-02-19 09:38:36.000000000 -0500 |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
21 |
*************** |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
22 |
*** 1008,1011 **** |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
23 |
--- 1008,1021 ---- |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
24 |
REDIRECTION_ERROR (r, errno, -1); |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
25 |
} |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
26 |
+ if ((flags & RX_UNDOABLE) && (ri == r_move_input || ri == r_move_output)) |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
27 |
+ { |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
28 |
+ /* r_move_input and r_move_output add an additional close() |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
29 |
+ that needs to be undone */ |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
30 |
+ if (fcntl (redirector, F_GETFD, 0) != -1) |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
31 |
+ { |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
32 |
+ r = add_undo_redirect (redir_fd, r_close_this, -1); |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
33 |
+ REDIRECTION_ERROR (r, errno, -1); |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
34 |
+ } |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
35 |
+ } |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
36 |
#if defined (BUFFERED_INPUT) |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
37 |
check_bash_input (redirector); |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
38 |
|
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
39 |
*** ../bash-4.2-patched/patchlevel.h Sat Jun 12 20:14:48 2010 |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
40 |
--- patchlevel.h Thu Feb 24 21:41:34 2011 |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
41 |
*************** |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
42 |
*** 26,30 **** |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
43 |
looks for to find the patch level (for the sccs version string). */ |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
44 |
|
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
45 |
! #define PATCHLEVEL 44 |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
46 |
|
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
47 |
#endif /* _PATCHLEVEL_H_ */ |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
48 |
--- 26,30 ---- |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
49 |
looks for to find the patch level (for the sccs version string). */ |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
50 |
|
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
51 |
! #define PATCHLEVEL 45 |
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
52 |
|
03b86a2f9021
16522397 bash in S12 should be 64-bit
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff
changeset
|
53 |
#endif /* _PATCHLEVEL_H_ */ |