bug-cpio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-cpio] directory times not restored


From: Tim Kientzle
Subject: Re: [Bug-cpio] directory times not restored
Date: Wed, 25 Mar 2009 11:56:46 -0700
User-agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.8.1.19) Gecko/20090226 SeaMonkey/1.1.14

Jeph Cowan wrote:

The modification date/times of the files are maintained as original,
but the date/time of the directories is the date/time of the restore.

What version?

I seem to recall Sergey fixing this in GNU cpio
fairly recently.

It seems that this may not be possible as the act of putting(restoring)
the files into the directory is in fact a modification.

It is tricky to implement.  The technique I used for
libarchive (which I believe is the same technique
Sergey used for GNU cpio) is to keep a list in memory
of directories and mtimes and then set the mtimes at
the very end, after all of the files have been written.
The same technique can be used to correctly restore
directories that are not writable or which have
restrictive file flags or ACLs.

Tim




reply via email to

[Prev in Thread] Current Thread [Next in Thread]