Bug 13076

Summary: Re: pr bin/9123 pax can't read tar archives that contain files >4GB
Product: Base System Reporter: Adrian Chadd <adrian>
Component: binAssignee: freebsd-bugs (Nobody) <bugs>
Status: Closed FIXED    
Severity: Affects Only Me CC: rtm
Priority: Normal    
Version: 1.0-RELEASE   
Hardware: Any   
OS: Any   

Description Adrian Chadd freebsd_committer freebsd_triage 1999-08-11 15:30:01 UTC
 The patch submitted works fine as far as I can tell, however I'd be
 tempted to typecast it to off_t since that is what st_size wants.
 
 
 Index: tar.c
 ===================================================================
 RCS file: /home/ncvs/src/bin/pax/tar.c,v
 retrieving revision 1.12
 diff -u -r1.12 tar.c
 --- tar.c       1999/05/08 10:21:20     1.12
 +++ tar.c       1999/08/11 14:24:07
 @@ -459,7 +459,7 @@
             0xfff);
         arcn->sb.st_uid = (uid_t)asc_ul(hd->uid, sizeof(hd->uid), OCT);
         arcn->sb.st_gid = (gid_t)asc_ul(hd->gid, sizeof(hd->gid), OCT);
 -       arcn->sb.st_size = (size_t)asc_ul(hd->size, sizeof(hd->size), OCT);
 +       arcn->sb.st_size = (off_t)asc_uqd(hd->size, sizeof(hd->size), OCT);
         arcn->sb.st_mtime = (time_t)asc_ul(hd->mtime, sizeof(hd->mtime), OCT);
         arcn->sb.st_ctime = arcn->sb.st_atime = arcn->sb.st_mtime;
  
 @@ -840,7 +840,7 @@
          */
         arcn->sb.st_mode = (mode_t)(asc_ul(hd->mode, sizeof(hd->mode), OCT) &
             0xfff);
 -       arcn->sb.st_size = (size_t)asc_ul(hd->size, sizeof(hd->size), OCT);
 +       arcn->sb.st_size = (off_t)asc_uqd(hd->size, sizeof(hd->size), OCT);
         arcn->sb.st_mtime = (time_t)asc_ul(hd->mtime, sizeof(hd->mtime), OCT);
         arcn->sb.st_ctime = arcn->sb.st_atime = arcn->sb.st_mtime;
 
 See if it works for you, if it does, let me know and it should be committed.
 
 
 Adrian
Comment 1 hoek freebsd_committer freebsd_triage 1999-08-22 21:51:47 UTC
Responsible Changed
From-To: gnats-admin->freebsd-bugs

Misfiled Pr. 


Comment 2 hoek freebsd_committer freebsd_triage 1999-08-22 21:53:25 UTC
State Changed
From-To: open->closed

Bastard PR.