cpio -dumpl damages the files?

Vladimir Grebenschikov vova at fbsd.ru
Tue Jul 1 16:45:36 UTC 2008


On Tue, 2008-07-01 at 08:56 -0700, Tim Kientzle wrote:
> Vladimir Grebenschikov wrote:
> > On Mon, 2008-06-30 at 22:46 -0700, Tim Kientzle wrote:
> > 
> >>Vladimir Grebenschikov wrote:
> >>
> >>>
> >>>Files are not corrupted any more, but strange message for every
> >>>directory still shown.
> >>
> >>Yes.  I think I just fixed this.  Please let me know if
> >>you see any other problems.
> > 
> > Now it works ok with directories, but I think, condition is too generic:
> > 
> > +       if (cpio->option_link
> > +           && archive_entry_filetype(entry) != AE_IFDIR)
> > +       {
> 
> [ ... example showing breakage copying symlinks ... ]
> 
> Try adding the following to the above condition:
> 
>      && archive_entry_filetype(entry) != AE_IFLNK

I guess it will work. I just wander about other AE_IF* that may not pass
link(2).

-- 
Vladimir B. Grebenschikov
vova at fbsd.ru


More information about the freebsd-current mailing list