Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 31 Mar 2001 00:33:04 +0300
From:      Vladimir Tchoukharev <chu@h33.erkki.ton.tut.fi>
To:        Poul-Henning Kamp <phk@critter.freebsd.dk>
Cc:        freebsd-bugs@FreeBSD.ORG
Subject:   Re: bin/25620: tar does not handle existing large minor numbers
Message-ID:  <3AC4FB8F.6FEE5042@h33.erkki.ton.tut.fi>
References:  <21332.985979947@critter>

next in thread | previous in thread | raw e-mail | index | archive | help
Poul-Henning Kamp wrote:
> 
> In message <3AC4DB99.62BFF666@h33.erkki.ton.tut.fi>, Vladimir Tchoukharev write
> s:
> >Poul-Henning Kamp wrote:
> >>
> >> Send a patch :-)
> >>
> >
> >OK, you asked for it...
> >
> >$ diff -u tar.1.orig tar.1
> >--- tar.1.orig  Fri Mar 30 21:56:26 2001
> >+++ tar.1       Fri Mar 30 22:08:33 2001
> >@@ -569,4 +569,5 @@
> > The tar file format is a semi fixed width field format, and the field
> > for device numbers were designed for 16 bit (8 major, 8 minor)
> > and can not absorb our 32 bit (8 major, 16+8 minor) numbers.
> >+Currently it is extended to support 21-bit minor numbers.
> 
> Now comes the good question:  which 21 bit ?

LSB?

> In FreeBSD the minor and major are interleaved:

But not in tar format. 

>         mmmmmmmm mmmmmmmm MMMMMMMM mmmmmmmm
> 
> I suspect that we only get 13 bits of minors with the 21 bit format:

I don't think so.  At least device
 crw-r-----   2 root  operator  116, 0x0005001a  8 ΖΕΧ 23:31 rad3s4
can be copied by tar correctly, despite of apparent 19 bit minor.

Ask bde to be sure. He writes in comments about a byte wasted by
to_oct(),
and that compatibility with previous version is saved. 

>         mmmmmmmm mmmmmmmm MMMMMMMM mmmmmmmm
>         -------- ---vvvvv vvvvvvvv vvvvvvvv
> 
> --
> Poul-Henning Kamp       | UNIX since Zilog Zeus 3.20
> phk@FreeBSD.ORG         | TCP/IP since RFC 956
> FreeBSD committer       | BSD since 4.3-tahoe
> Never attribute to malice what can adequately be explained by incompetence.

Best regards,
V. Tchoukharev

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?3AC4FB8F.6FEE5042>