packages: bash/bash40-025 (NEW), bash/bash40-026 (NEW), bash/bash40-027 (NE...

arekm arekm at pld-linux.org
Fri Jul 31 22:48:41 CEST 2009


Author: arekm                        Date: Fri Jul 31 20:48:41 2009 GMT
Module: packages                      Tag: HEAD
---- Log message:
- up to 4.0.28

---- Files affected:
packages/bash:
   bash40-025 (NONE -> 1.1)  (NEW), bash40-026 (NONE -> 1.1)  (NEW), bash40-027 (NONE -> 1.1)  (NEW), bash40-028 (NONE -> 1.1)  (NEW)

---- Diffs:

================================================================
Index: packages/bash/bash40-025
diff -u /dev/null packages/bash/bash40-025:1.1
--- /dev/null	Fri Jul 31 22:48:41 2009
+++ packages/bash/bash40-025	Fri Jul 31 22:48:35 2009
@@ -0,0 +1,104 @@
+			     BASH PATCH REPORT
+			     =================
+
+Bash-Release:	4.0
+Patch-ID:	bash40-025
+
+Bug-Reported-by:	Matt Zyzik <matt.zyzik at nyu.edu>
+Bug-Reference-ID:	<20090519011418.GA21431 at ice.filescope.com>
+Bug-Reference-URL:	http://lists.gnu.org/archive/html/bug-bash/2009-05/msg00044.html
+
+Bug-Description:
+
+bash40-024 introduced a regression for constructs like **/*.cs; that
+expansion would no longer include matching files in the current directory.
+This patch undoes portions of bash40-024 and fixes the original problem
+in a different way.
+
+Patch:
+
+*** ../bash-4.0-patched/lib/glob/glob.c	2009-05-22 12:32:26.000000000 -0400
+--- lib/glob/glob.c	2009-05-22 12:35:55.000000000 -0400
+***************
+*** 666,672 ****
+      }
+  
+!   /* compat: if GX_ALLDIRS, add the passed directory also, but don't add an
+!      empty directory name. */
+!   if (add_current && (flags & GX_NULLDIR) == 0)
+      {
+        sdlen = strlen (dir);
+--- 666,673 ----
+      }
+  
+!   /* compat: if GX_ADDCURDIR, add the passed directory also.  Add an empty
+!      directory name as a placeholder if GX_NULLDIR (in which case the passed
+!      directory name is "."). */
+!   if (add_current)
+      {
+        sdlen = strlen (dir);
+***************
+*** 680,684 ****
+  	  nextlink->next = lastlink;
+  	  lastlink = nextlink;
+! 	  bcopy (dir, nextname, sdlen + 1);
+  	  ++count;
+  	}
+--- 681,688 ----
+  	  nextlink->next = lastlink;
+  	  lastlink = nextlink;
+! 	  if (flags & GX_NULLDIR)
+! 	    nextname[0] = '\0';
+! 	  else
+! 	    bcopy (dir, nextname, sdlen + 1);
+  	  ++count;
+  	}
+***************
+*** 1008,1016 ****
+        /* Just return what glob_vector () returns appended to the
+  	 directory name. */
+        dflags = flags & ~GX_MARKDIRS;
+        if (directory_len == 0)
+  	dflags |= GX_NULLDIR;
+        if ((flags & GX_GLOBSTAR) && filename[0] == '*' && filename[1] == '*' && filename[2] == '\0')
+! 	dflags |= GX_ALLDIRS|GX_ADDCURDIR;
+        temp_results = glob_vector (filename,
+  				  (directory_len == 0 ? "." : directory_name),
+--- 1012,1033 ----
+        /* Just return what glob_vector () returns appended to the
+  	 directory name. */
++       /* If flags & GX_ALLDIRS, we're called recursively */
+        dflags = flags & ~GX_MARKDIRS;
+        if (directory_len == 0)
+  	dflags |= GX_NULLDIR;
+        if ((flags & GX_GLOBSTAR) && filename[0] == '*' && filename[1] == '*' && filename[2] == '\0')
+! 	{
+! 	  dflags |= GX_ALLDIRS|GX_ADDCURDIR;
+! #if 0
+! 	  /* If we want all directories (dflags & GX_ALLDIRS) and we're not
+! 	     being called recursively as something like `echo **/*.o'
+! 	     ((flags & GX_ALLDIRS) == 0), we want to prevent glob_vector from
+! 	     adding a null directory name to the front of the temp_results
+! 	     array.  We turn off ADDCURDIR if not called recursively and
+! 	     dlen == 0 */
+! #endif
+! 	  if (directory_len == 0 && (flags & GX_ALLDIRS) == 0)
+! 	    dflags &= ~GX_ADDCURDIR;
+! 	}
+        temp_results = glob_vector (filename,
+  				  (directory_len == 0 ? "." : directory_name),
+*** ../bash-4.0/patchlevel.h	2009-01-04 14:32:40.000000000 -0500
+--- patchlevel.h	2009-02-22 16:11:31.000000000 -0500
+***************
+*** 26,30 ****
+     looks for to find the patch level (for the sccs version string). */
+  
+! #define PATCHLEVEL 24
+  
+  #endif /* _PATCHLEVEL_H_ */
+--- 26,30 ----
+     looks for to find the patch level (for the sccs version string). */
+  
+! #define PATCHLEVEL 25
+  
+  #endif /* _PATCHLEVEL_H_ */

================================================================
Index: packages/bash/bash40-026
diff -u /dev/null packages/bash/bash40-026:1.1
--- /dev/null	Fri Jul 31 22:48:41 2009
+++ packages/bash/bash40-026	Fri Jul 31 22:48:35 2009
@@ -0,0 +1,56 @@
+			     BASH PATCH REPORT
+			     =================
+
+Bash-Release:	4.0
+Patch-ID:	bash40-026
+
+Bug-Reported-by:	Sergei Steshenko <sergstesh at yahoo.com>
+Bug-Reference-ID:	<670181.38883.qm at web35204.mail.mud.yahoo.com>
+Bug-Reference-URL:	http://lists.gnu.org/archive/html/bug-bash/2009-05/msg00059.html
+
+Bug-Description:
+
+A forgotten line in externs.h caused compilation errors to occur on some
+systems (e.g., Cygwin).
+
+Patch:
+
+*** ../bash-4.0-patched/externs.h	2009-01-18 18:29:29.000000000 -0500
+--- externs.h	2009-06-02 09:05:40.000000000 -0400
+***************
+*** 193,196 ****
+--- 193,198 ----
+  
+  /* Declarations for functions defined in lib/sh/fpurge.c */
++ 
++ #if defined NEED_FPURGE_DECL
+  #if !HAVE_DECL_FPURGE
+  
+***************
+*** 201,205 ****
+  
+  #endif /* HAVE_DECL_FPURGE */
+! 
+  
+  /* Declarations for functions defined in lib/sh/getcwd.c */
+--- 203,207 ----
+  
+  #endif /* HAVE_DECL_FPURGE */
+! #endif /* NEED_FPURGE_DECL */
+  
+  /* Declarations for functions defined in lib/sh/getcwd.c */
+*** ../bash-4.0/patchlevel.h	2009-01-04 14:32:40.000000000 -0500
+--- patchlevel.h	2009-02-22 16:11:31.000000000 -0500
+***************
+*** 26,30 ****
+     looks for to find the patch level (for the sccs version string). */
+  
+! #define PATCHLEVEL 25
+  
+  #endif /* _PATCHLEVEL_H_ */
+--- 26,30 ----
+     looks for to find the patch level (for the sccs version string). */
+  
+! #define PATCHLEVEL 26
+  
+  #endif /* _PATCHLEVEL_H_ */

================================================================
Index: packages/bash/bash40-027
diff -u /dev/null packages/bash/bash40-027:1.1
--- /dev/null	Fri Jul 31 22:48:41 2009
+++ packages/bash/bash40-027	Fri Jul 31 22:48:35 2009
@@ -0,0 +1,67 @@
+			     BASH PATCH REPORT
+			     =================
+
+Bash-Release:	4.0
+Patch-ID: bash40-027
+
+Bug-Reported-by:	jim at jim.sh
+Bug-Reference-ID:	<200905262140.n4QLeO4X030664 at psychosis.jim.sh>
+Bug-Reference-URL:	http://lists.gnu.org/archive/html/bug-bash/2009-05/msg00074.html
+
+Bug-Description:
+
+There are occasional cursor positioning errors when using readline's
+horizontal scroll mode.
+
+Patch:
+
+*** ../bash-4.0-patched/lib/readline/display.c	2009-05-22 12:32:25.000000000 -0400
+--- lib/readline/display.c	2009-05-29 23:32:20.000000000 -0400
+***************
+*** 1190,1196 ****
+  	line[t - 1] = '>';
+  
+!       if (!rl_display_fixed || forced_display || lmargin != last_lmargin)
+  	{
+  	  forced_display = 0;
+  	  update_line (&visible_line[last_lmargin],
+  		       &invisible_line[lmargin],
+--- 1192,1200 ----
+  	line[t - 1] = '>';
+  
+!       if (rl_display_fixed == 0 || forced_display || lmargin != last_lmargin)
+  	{
+  	  forced_display = 0;
++ 	  o_cpos = _rl_last_c_pos;
++ 	  cpos_adjusted = 0;
+  	  update_line (&visible_line[last_lmargin],
+  		       &invisible_line[lmargin],
+***************
+*** 1200,1203 ****
+--- 1204,1214 ----
+  		       0);
+  
++ 	  if ((MB_CUR_MAX > 1 && rl_byte_oriented == 0) &&
++ 	      cpos_adjusted == 0 &&
++ 	      _rl_last_c_pos != o_cpos &&
++ 	      _rl_last_c_pos > wrap_offset &&
++ 	      o_cpos < prompt_last_invisible)
++ 		_rl_last_c_pos -= prompt_invis_chars_first_line;	/* XXX - was wrap_offset */
++ 
+  	  /* If the visible new line is shorter than the old, but the number
+  	     of invisible characters is greater, and we are at the end of
+*** ../bash-4.0/patchlevel.h	2009-01-04 14:32:40.000000000 -0500
+--- patchlevel.h	2009-02-22 16:11:31.000000000 -0500
+***************
+*** 26,30 ****
+     looks for to find the patch level (for the sccs version string). */
+  
+! #define PATCHLEVEL 26
+  
+  #endif /* _PATCHLEVEL_H_ */
+--- 26,30 ----
+     looks for to find the patch level (for the sccs version string). */
+  
+! #define PATCHLEVEL 27
+  
+  #endif /* _PATCHLEVEL_H_ */

================================================================
Index: packages/bash/bash40-028
diff -u /dev/null packages/bash/bash40-028:1.1
--- /dev/null	Fri Jul 31 22:48:41 2009
+++ packages/bash/bash40-028	Fri Jul 31 22:48:35 2009
@@ -0,0 +1,172 @@
+			     BASH PATCH REPORT
+			     =================
+
+Bash-Release:	4.0
+Patch-ID:	bash40-028
+
+Bug-Reported-by:	martin f krafft <madduck at debian.org>
+Bug-Reference-ID:	<4A4E39E7.5080807 at debian.org>
+Bug-Reference-URL:	http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=519165
+			http://lists.gnu.org/archive/html/bug-bash/2009-07/msg00011.html
+
+Bug-Description:
+
+bash-4.0 reverted to the historical shell behavior of raising an error
+when $@ or $* was expanded after `set -u' had been executed and there
+were no positional parameters.  The Posix working group has since
+clarified the standard's position on the issue, and $@ and $* are now the
+only variables, parameters, or special parameters that do not raise an
+error when unset if set -u is enabled.
+
+Patch:
+
+*** ../bash-4.0-patched/subst.c	Mon Mar 23 11:34:55 2009
+--- subst.c	Wed Jun 17 18:12:18 2009
+***************
+*** 6768,6778 ****
+  
+      case RBRACE:
+!       if (var_is_set == 0 && unbound_vars_is_error)
+  	{
+  	  err_unboundvar (name);
+  	  FREE (value);
+  	  FREE (temp);
+  	  free (name);
+- 	  last_command_exit_value = EXECUTION_FAILURE;
+  	  return (interactive_shell ? &expand_wdesc_error : &expand_wdesc_fatal);
+  	}
+--- 6794,6804 ----
+  
+      case RBRACE:
+!       if (var_is_set == 0 && unbound_vars_is_error && ((name[0] != '@' && name[0] != '*') || name[1]))
+  	{
++ 	  last_command_exit_value = EXECUTION_FAILURE;
+  	  err_unboundvar (name);
+  	  FREE (value);
+  	  FREE (temp);
+  	  free (name);
+  	  return (interactive_shell ? &expand_wdesc_error : &expand_wdesc_fatal);
+  	}
+***************
+*** 6991,6994 ****
+--- 7017,7029 ----
+        list = list_rest_of_args ();
+  
++ #if 0
++       /* According to austin-group posix proposal by Geoff Clare in
++ 	 <20090505091501.GA10097 at squonk.masqnet> of 5 May 2009:
++ 
++  	"The shell shall write a message to standard error and
++  	 immediately exit when it tries to expand an unset parameter
++  	 other than the '@' and '*' special parameters."
++       */
++ 
+        if (list == 0 && unbound_vars_is_error && (pflags & PF_IGNUNBOUND) == 0)
+  	{
+***************
+*** 6996,7003 ****
+  	  uerror[1] = '*';
+  	  uerror[2] = '\0';
+- 	  err_unboundvar (uerror);
+  	  last_command_exit_value = EXECUTION_FAILURE;
+  	  return (interactive_shell ? &expand_wdesc_error : &expand_wdesc_fatal);
+  	}
+  
+        /* If there are no command-line arguments, this should just
+--- 7031,7039 ----
+  	  uerror[1] = '*';
+  	  uerror[2] = '\0';
+  	  last_command_exit_value = EXECUTION_FAILURE;
++ 	  err_unboundvar (uerror);
+  	  return (interactive_shell ? &expand_wdesc_error : &expand_wdesc_fatal);
+  	}
++ #endif
+  
+        /* If there are no command-line arguments, this should just
+***************
+*** 7053,7056 ****
+--- 7089,7101 ----
+        list = list_rest_of_args ();
+  
++ #if 0
++       /* According to austin-group posix proposal by Geoff Clare in
++ 	 <20090505091501.GA10097 at squonk.masqnet> of 5 May 2009:
++ 
++  	"The shell shall write a message to standard error and
++  	 immediately exit when it tries to expand an unset parameter
++  	 other than the '@' and '*' special parameters."
++       */
++ 
+        if (list == 0 && unbound_vars_is_error && (pflags & PF_IGNUNBOUND) == 0)
+  	{
+***************
+*** 7058,7065 ****
+  	  uerror[1] = '@';
+  	  uerror[2] = '\0';
+- 	  err_unboundvar (uerror);
+  	  last_command_exit_value = EXECUTION_FAILURE;
+  	  return (interactive_shell ? &expand_wdesc_error : &expand_wdesc_fatal);
+  	}
+  
+        /* We want to flag the fact that we saw this.  We can't turn
+--- 7103,7111 ----
+  	  uerror[1] = '@';
+  	  uerror[2] = '\0';
+  	  last_command_exit_value = EXECUTION_FAILURE;
++ 	  err_unboundvar (uerror);
+  	  return (interactive_shell ? &expand_wdesc_error : &expand_wdesc_fatal);
+  	}
++ #endif
+  
+        /* We want to flag the fact that we saw this.  We can't turn
+*** ../bash-4.0-patched/doc/bash.1	Wed Feb 18 15:13:56 2009
+--- doc/bash.1	Wed Jun 17 08:51:19 2009
+***************
+*** 8258,8264 ****
+  .TP 8
+  .B \-u
+! Treat unset variables as an error when performing
+  parameter expansion.  If expansion is attempted on an
+! unset variable, the shell prints an error message, and,
+  if not interactive, exits with a non-zero status.
+  .TP 8
+--- 8274,8281 ----
+  .TP 8
+  .B \-u
+! Treat unset variables and parameters other than the special
+! parameters "@" and "*" as an error when performing
+  parameter expansion.  If expansion is attempted on an
+! unset variable or parameter, the shell prints an error message, and,
+  if not interactive, exits with a non-zero status.
+  .TP 8
+*** ../bash-4.0-patched/doc/bashref.texi	Wed Feb 18 15:14:43 2009
+--- doc/bashref.texi	Wed Jun 17 08:50:46 2009
+***************
+*** 4139,4143 ****
+  
+  @item -u
+! Treat unset variables as an error when performing parameter expansion.
+  An error message will be written to the standard error, and a non-interactive
+  shell will exit.
+--- 4151,4156 ----
+  
+  @item -u
+! Treat unset variables and parameters other than the special parameters
+! @samp{@@} or @samp{*} as an error when performing parameter expansion.
+  An error message will be written to the standard error, and a non-interactive
+  shell will exit.
+*** ../bash-4.0/patchlevel.h	2009-01-04 14:32:40.000000000 -0500
+--- patchlevel.h	2009-02-22 16:11:31.000000000 -0500
+***************
+*** 26,30 ****
+     looks for to find the patch level (for the sccs version string). */
+  
+! #define PATCHLEVEL 27
+  
+  #endif /* _PATCHLEVEL_H_ */
+--- 26,30 ----
+     looks for to find the patch level (for the sccs version string). */
+  
+! #define PATCHLEVEL 28
+  
+  #endif /* _PATCHLEVEL_H_ */
================================================================


More information about the pld-cvs-commit mailing list