Re: [Bug-tar] interix timestamp issues

2011-05-13 Thread Eric Blake
On 05/13/2011 07:07 AM, Markus Duft wrote: > On 05/13/11 08:27, Paul Eggert wrote: >> On 05/12/11 23:15, Markus Duft wrote: >>> maybe i could even implement a futimes by memorizing the timestamps and >>> re-setting them after closing the file... Of course, you should not reset timestamps if some

Re: [Bug-tar] interix timestamp issues

2011-05-13 Thread Markus Duft
On 05/13/11 08:27, Paul Eggert wrote: > On 05/12/11 23:15, Markus Duft wrote: >> maybe i could even implement a futimes by memorizing the timestamps and >> re-setting them after closing the file... >> >> would that be better than hacking around in gnulib? libsuacomp is required >> anyway to get a

Re: [Bug-tar] interix timestamp issues

2011-05-12 Thread Paul Eggert
On 05/12/11 23:15, Markus Duft wrote: > maybe i could even implement a futimes by memorizing the timestamps and > re-setting them after closing the file... > > would that be better than hacking around in gnulib? libsuacomp is required > anyway to get a more sane system. Yes, thanks, that sounds

Re: [Bug-tar] interix timestamp issues

2011-05-12 Thread Markus Duft
On 05/12/11 18:10, Paul Eggert wrote: > On 05/12/11 01:38, Markus Duft wrote: >> this doesn't help, and doesn't even compile, as interix also doesn't have >> sync() > > OK, how about this patch to utimens.c instead? tested, but doesn't help either. the problem is, that fdutimensat calls utimens

Re: [Bug-tar] interix timestamp issues

2011-05-12 Thread Paul Eggert
On 05/12/11 01:38, Markus Duft wrote: > this doesn't help, and doesn't even compile, as interix also doesn't have > sync() OK, how about this patch to utimens.c instead? diff --git a/lib/utimens.c b/lib/utimens.c index c190411..f738c68 100644 --- a/lib/utimens.c +++ b/lib/utimens.c @@ -58,6 +58,

Re: [Bug-tar] interix timestamp issues

2011-05-12 Thread Markus Duft
On 05/12/11 09:20, Paul Eggert wrote: > On 05/11/11 23:51, Markus Duft wrote: >> the fd in fdutimensat is 4, whereas in utimens, which is then called from >> somewhere in there, >> it is -1, so i can't do a fsync() > > If I understand things correctly, there's a simpler fix. fdutimensat calls >

Re: [Bug-tar] interix timestamp issues

2011-05-12 Thread Paul Eggert
On 05/11/11 23:51, Markus Duft wrote: > the fd in fdutimensat is 4, whereas in utimens, which is then called from > somewhere in there, > it is -1, so i can't do a fsync() If I understand things correctly, there's a simpler fix. fdutimensat calls futimens (fd, ts), which invokes fdutimens (fd, N

Re: [Bug-tar] interix timestamp issues (was: listed-incremental broken in 1.25 on Solaris 10)

2011-05-11 Thread Markus Duft
On 05/12/11 05:41, Paul Eggert wrote: > On 05/11/11 01:49, Markus Duft wrote: >> fsync(fd) before setting the timestamp helps, and i have a 1.26 patch >> (attached), >> for now limited to interix only, although i saw it on linux too. > > Can you describe the GNU/Linux scenario? That would be a s