From adrian@freebsd.org Wed Aug 11 07:22:00 1999
Return-Path: <adrian@freebsd.org>
Received: from ewok.creative.net.au (ewok.creative.net.au [203.30.44.41])
	by hub.freebsd.org (Postfix) with SMTP id A137415225
	for <freebsd-gnats-submit@freebsd.org>; Wed, 11 Aug 1999 07:21:44 -0700 (PDT)
	(envelope-from adrian@freebsd.org)
Received: (qmail 6872 invoked by uid 1008); 11 Aug 1999 14:21:46 -0000
Message-Id: <19990811222145.A6801@ewok.creative.net.au>
Date: Wed, 11 Aug 1999 22:21:46 +0800
From: adrian@freebsd.org
To: freebsd-gnats-submit@freebsd.org
Cc: rtm@eecs.harvard.edu
Subject: Re: pr bin/9123 pax can't read tar archives that contain files >4GB

>Number:         13076
>Category:       bin
>Synopsis:       Re: pr bin/9123 pax can't read tar archives that contain files >4GB
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Aug 11 07:30:01 PDT 1999
>Closed-Date:    Sun Aug 22 13:53:25 PDT 1999
>Last-Modified:  Sun Aug 22 13:53:38 PDT 1999
>Originator:     
>Release:        
>Organization:
>Environment:
>Description:
 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
 
>How-To-Repeat:
>Fix:
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: gnats-admin->freebsd-bugs 
Responsible-Changed-By: hoek 
Responsible-Changed-When: Sun Aug 22 13:51:47 PDT 1999 
Responsible-Changed-Why:  
Misfiled Pr. 


State-Changed-From-To: open->closed 
State-Changed-By: hoek 
State-Changed-When: Sun Aug 22 13:53:25 PDT 1999 
State-Changed-Why:  
Bastard PR. 
>Unformatted:
