Roman Rakus d1932b
			     BASH PATCH REPORT
Roman Rakus d1932b
			     =================
Roman Rakus d1932b
Roman Rakus d1932b
Bash-Release: 3.2
Roman Rakus d1932b
Patch-ID: bash32-048
Roman Rakus d1932b
Roman Rakus d1932b
Bug-Reported-by:	Steffen Kiess <s-kiess@web.de>
Roman Rakus d1932b
Bug-Reference-ID:	<1223929957.5383.6.camel@fips>
Roman Rakus d1932b
Bug-Reference-URL:	http://lists.gnu.org/archive/html/bug-bash/2008-10/msg00047.html
Roman Rakus d1932b
Roman Rakus d1932b
Bug-Description:
Roman Rakus d1932b
Roman Rakus d1932b
When invoked as `bash -c', bash did not execute an EXIT trap when the last
Roman Rakus d1932b
command in the executed list was a command run from the file system.
Roman Rakus d1932b
Roman Rakus d1932b
Patch:
Roman Rakus d1932b
Roman Rakus d1932b
*** /Users/chet/src/bash/bash-3.2-patched/builtins/evalstring.c	2006-07-28 15:12:16.000000000 -0400
Roman Rakus d1932b
--- builtins/evalstring.c	2008-11-13 18:38:45.000000000 -0500
Roman Rakus d1932b
***************
Roman Rakus d1932b
*** 249,252 ****
Roman Rakus d1932b
--- 249,253 ----
Roman Rakus d1932b
  	       *   we're not running a trap AND
Roman Rakus d1932b
  	       *   we have parsed the full command (string == '\0') AND
Roman Rakus d1932b
+ 	       *   we're not going to run the exit trap AND
Roman Rakus d1932b
  	       *   we have a simple command without redirections AND
Roman Rakus d1932b
  	       *   the command is not being timed AND
Roman Rakus d1932b
***************
Roman Rakus d1932b
*** 259,263 ****
Roman Rakus d1932b
  		  *bash_input.location.string == '\0' &&
Roman Rakus d1932b
  		  command->type == cm_simple &&
Roman Rakus d1932b
! 		  !command->redirects && !command->value.Simple->redirects &&
Roman Rakus d1932b
  		  ((command->flags & CMD_TIME_PIPELINE) == 0) &&
Roman Rakus d1932b
  		  ((command->flags & CMD_INVERT_RETURN) == 0))
Roman Rakus d1932b
--- 260,265 ----
Roman Rakus d1932b
  		  *bash_input.location.string == '\0' &&
Roman Rakus d1932b
  		  command->type == cm_simple &&
Roman Rakus d1932b
! 		  signal_is_trapped (EXIT_TRAP) == 0 &&
Roman Rakus d1932b
! 		  command->redirects == 0 && command->value.Simple->redirects == 0 &&
Roman Rakus d1932b
  		  ((command->flags & CMD_TIME_PIPELINE) == 0) &&
Roman Rakus d1932b
  		  ((command->flags & CMD_INVERT_RETURN) == 0))
Roman Rakus d1932b
*** ../bash-3.2/patchlevel.h	Thu Apr 13 08:31:04 2006
Roman Rakus d1932b
--- patchlevel.h	Mon Oct 16 14:22:54 2006
Roman Rakus d1932b
***************
Roman Rakus d1932b
*** 26,30 ****
Roman Rakus d1932b
     looks for to find the patch level (for the sccs version string). */
Roman Rakus d1932b
  
Roman Rakus d1932b
! #define PATCHLEVEL 47
Roman Rakus d1932b
  
Roman Rakus d1932b
  #endif /* _PATCHLEVEL_H_ */
Roman Rakus d1932b
--- 26,30 ----
Roman Rakus d1932b
     looks for to find the patch level (for the sccs version string). */
Roman Rakus d1932b
  
Roman Rakus d1932b
! #define PATCHLEVEL 48
Roman Rakus d1932b
  
Roman Rakus d1932b
  #endif /* _PATCHLEVEL_H_ */