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-022
07a490
07a490
Bug-Reported-by:	Gregory Margo <gmargo@pacbell.net>
07a490
Bug-Reference-ID:	<20110727174529.GA3333@pacbell.net>
07a490
Bug-Reference-URL:	http://lists.gnu.org/archive/html/bug-bash/2011-07/msg00102.html
07a490
07a490
Bug-Description:
07a490
07a490
The return value from lseek is `off_t'.  This can cause corrupted return
07a490
values when the file offset is greater than 2**31 - 1.
07a490
07a490
Patch (apply with `patch -p0'):
07a490
07a490
*** ../bash-4.2-patched/lib/sh/zread.c	Mon Mar  2 08:54:45 2009
07a490
--- lib/sh/zread.c	Thu Jul 28 18:16:53 2011
07a490
***************
07a490
*** 161,166 ****
07a490
       int fd;
07a490
  {
07a490
!   off_t off;
07a490
!   int r;
07a490
  
07a490
    off = lused - lind;
07a490
--- 161,165 ----
07a490
       int fd;
07a490
  {
07a490
!   off_t off, r;
07a490
  
07a490
    off = lused - lind;
07a490
***************
07a490
*** 169,173 ****
07a490
      r = lseek (fd, -off, SEEK_CUR);
07a490
  
07a490
!   if (r >= 0)
07a490
      lused = lind = 0;
07a490
  }
07a490
--- 168,172 ----
07a490
      r = lseek (fd, -off, SEEK_CUR);
07a490
  
07a490
!   if (r != -1)
07a490
      lused = lind = 0;
07a490
  }
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 21
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 22
07a490
  
07a490
  #endif /* _PATCHLEVEL_H_ */