rcolebaugh / rpms / bash

Forked from rpms/bash 2 years ago
Clone
07a490
			     BASH PATCH REPORT
07a490
			     =================
07a490
07a490
Bash-Release:	4.2
07a490
Patch-ID:	bash42-004
07a490
07a490
Bug-Reported-by:	Mike Frysinger <vapier@gentoo.org>
07a490
Bug-Reference-ID:	<201102182106.17834.vapier@gentoo.org>
07a490
Bug-Reference-URL:	http://lists.gnu.org/archive/html/bug-bash/2011-02/msg00222.html
07a490
07a490
Bug-Description:
07a490
07a490
When used in contexts where word splitting and quote removal were not
07a490
performed, such as pattern removal or pattern substitution, empty strings
07a490
(either literal or resulting from quoted variables that were unset or
07a490
null) were not matched correctly, resulting in failure.
07a490
07a490
Patch (apply with `patch -p0'):
07a490
07a490
*** ../bash-4.2-patched/subst.c	2011-01-02 16:12:51.000000000 -0500
07a490
--- subst.c	2011-02-18 22:30:13.000000000 -0500
07a490
***************
07a490
*** 3373,3379 ****
07a490
    if (string == 0 || *string == '\0')
07a490
      return (WORD_LIST *)NULL;
07a490
  
07a490
!   td.flags = 0;
07a490
    td.word = string;
07a490
    tresult = call_expand_word_internal (&td, quoted, 1, dollar_at_p, has_dollar_at);
07a490
    return (tresult);
07a490
--- 3373,3379 ----
07a490
    if (string == 0 || *string == '\0')
07a490
      return (WORD_LIST *)NULL;
07a490
  
07a490
!   td.flags = W_NOSPLIT2;		/* no splitting, remove "" and '' */
07a490
    td.word = string;
07a490
    tresult = call_expand_word_internal (&td, quoted, 1, dollar_at_p, has_dollar_at);
07a490
    return (tresult);
07a490
*** ../bash-4.2-patched/patchlevel.h	Sat Jun 12 20:14:48 2010
07a490
--- patchlevel.h	Thu Feb 24 21:41:34 2011
07a490
***************
07a490
*** 26,30 ****
07a490
     looks for to find the patch level (for the sccs version string). */
07a490
  
07a490
! #define PATCHLEVEL 3
07a490
  
07a490
  #endif /* _PATCHLEVEL_H_ */
07a490
--- 26,30 ----
07a490
     looks for to find the patch level (for the sccs version string). */
07a490
  
07a490
! #define PATCHLEVEL 4
07a490
  
07a490
  #endif /* _PATCHLEVEL_H_ */