rcolebaugh / rpms / bash

Forked from rpms/bash 2 years ago
Clone
462fb2
			     BASH PATCH REPORT
462fb2
			     =================
462fb2
462fb2
Bash-Release:	4.2
462fb2
Patch-ID:	bash42-024
462fb2
462fb2
Bug-Reported-by:	Jim Avera <james_avera@yahoo.com>
462fb2
Bug-Reference-ID:	<4F29E07A.80405@yahoo.com>
462fb2
Bug-Reference-URL:	http://lists.gnu.org/archive/html/bug-bash/2012-02/msg00001.html
462fb2
462fb2
Bug-Description:
462fb2
462fb2
When `printf -v' is used to set an array element, the format string contains
462fb2
`%b', and the corresponding argument is the empty string, the buffer used
462fb2
to store the value to be assigned can be NULL, which results in NUL being
462fb2
assigned to the array element.  This causes a seg fault when it's used later.
462fb2
462fb2
Patch (apply with `patch -p0'):
462fb2
462fb2
*** ../bash-4.2-patched/builtins/printf.def	2011-02-25 12:07:41.000000000 -0500
462fb2
--- builtins/printf.def	2012-02-02 08:37:12.000000000 -0500
462fb2
***************
462fb2
*** 256,259 ****
462fb2
--- 257,262 ----
462fb2
  	    {
462fb2
  	      vflag = 1;
462fb2
+ 	      if (vbsize == 0)
462fb2
+ 		vbuf = xmalloc (vbsize = 16);
462fb2
  	      vblen = 0;
462fb2
  	      if (vbuf)
462fb2
*** ../bash-4.2-patched/patchlevel.h	Sat Jun 12 20:14:48 2010
462fb2
--- patchlevel.h	Thu Feb 24 21:41:34 2011
462fb2
***************
462fb2
*** 26,30 ****
462fb2
     looks for to find the patch level (for the sccs version string). */
462fb2
  
462fb2
! #define PATCHLEVEL 23
462fb2
  
462fb2
  #endif /* _PATCHLEVEL_H_ */
462fb2
--- 26,30 ----
462fb2
     looks for to find the patch level (for the sccs version string). */
462fb2
  
462fb2
! #define PATCHLEVEL 24
462fb2
  
462fb2
  #endif /* _PATCHLEVEL_H_ */