[prev in list] [next in list] [prev in thread] [next in thread] 

List:       busybox
Subject:    Re: [BusyBox] seek_sub_file in unarchive.c broken?
From:       Matt Kraai <kraai () alumni ! carnegiemellon ! edu>
Date:       2001-09-25 9:25:16
[Download RAW message or body]

Howdy,

This is partially fixed in uClibc CVS.  I'm waiting for approval
to check in the second part of the fix.  If you are impatient, you
can apply the following to the latest CVS:

Index: libc/stdio/stdio.c
===================================================================
RCS file: /var/cvs/uClibc/libc/stdio/stdio.c,v
retrieving revision 1.32
diff -c -3 -p -r1.32 stdio.c
*** libc/stdio/stdio.c	2001/09/25 15:18:12	1.32
--- libc/stdio/stdio.c	2001/09/25 15:21:18
*************** int fseek(FILE *fp, long int offset, int
*** 592,598 ****
  
  	if ((fp->mode & __MODE_ERR) || 
  		(((ref != SEEK_CUR) || offset) && (lseek(fp->fd, offset, ref) < 0))) {
- 		fp->mode |= __MODE_ERR;	/* Possibly redundant, but doesn't hurt. */
  		return -1;
  	}
  
--- 592,597 ----

I believe that this should fix your problem.

Matt



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic