Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 18 Dec 1998 07:44:47 -0800 (PST)
From:      rtm@eecs.harvard.edu
To:        freebsd-gnats-submit@FreeBSD.ORG
Subject:   bin/9123: pax can't read tar archives that contain files > 4GB
Message-ID:  <199812181544.HAA21805@hub.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         9123
>Category:       bin
>Synopsis:       pax can't read tar archives that contain files > 4GB
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:
>Keywords:
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Dec 18 07:50:01 PST 1998
>Last-Modified:
>Originator:     Robert Morris
>Organization:
Harvard University
>Release:        2.2.6
>Environment:
FreeBSD frenulum.eecs.harvard.edu 2.2.7-RELEASE FreeBSD 2.2.7-RELEASE #0: Sat Sep  5 09:53:19 EDT 1998     rtm@frenulum.eecs.harvard.edu:/sys/compile/FRENULUM  i386
>Description:
pax treats the 12-digit octal file length field in the tar
per-file header as if it fit into a 32-bit int.
>How-To-Repeat:
Create a tar archive containing a file longer than 4GB.
Try to read the archive with pax.
>Fix:
Change /usr/src/bin/pax/tar.c:

460c460
<       arcn->sb.st_size = (size_t)asc_ul(hd->size, sizeof(hd->size), OCT);
---
>       arcn->sb.st_size = asc_uqd(hd->size, sizeof(hd->size), OCT);
841c841
<       arcn->sb.st_size = (size_t)asc_ul(hd->size, sizeof(hd->size), OCT);
---
>       arcn->sb.st_size = asc_uqd(hd->size, sizeof(hd->size), OCT);

>Audit-Trail:
>Unformatted:

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199812181544.HAA21805>