Date: Tue, 07 Aug 2001 20:54:57 +0300 From: "Eli Zaretskii" Sender: halo1 AT zahav DOT net DOT il To: acottrel AT ihug DOT com DOT au Message-Id: <2110-Tue07Aug2001205457+0300-eliz@is.elta.co.il> X-Mailer: Emacs 20.6 (via feedmail 8.3.emacs20_6 I) and Blat ver 1.8.9 CC: sandmann AT clio DOT rice DOT edu, djgpp-workers AT delorie DOT com In-reply-to: <012501c11f40$1b082090$0a02a8c0@acceleron> (acottrel@ihug.com.au) Subject: Re: Fw: Windows 2000 /dev/null permission query References: <012501c11f40$1b082090$0a02a8c0 AT acceleron> Reply-To: djgpp-workers AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp-workers AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk > From: "Andrew Cottrell" > Date: Tue, 7 Aug 2001 21:54:15 +1000 > > > Alternatively, we could use function 7143h to set file times directly, > > without opening it. Since this function is reported to sometimes fail > > on Windows 98 and ME, we should use this alternative only on W2K/XP > > (detectable by their DOS version, 5.50, together with LFN support). > > Assuming that 7143h doesn't have any surprised (a bold assumption, I > > know ;-), this would completely avoid the problem with LFN vs non-LFN > > handles. > Function 7143 works on my Win2K box, but due to buggy Win 9x > implementation this does not work on Win98. We could try 7143 and if that fails and the OS is 98 or ME, fall back on the current code. > Output of testing: > -rw-r--r-- 1 AC root 4 Aug 24 2001 new.txt > > 5700 call time cx = 0xB733 date dx = 0x2B18 r.x.flags = 0x0002 r.x.ax = > 0x5700 > 7143 call time cx = 0xB734 date di = 0x2B18 r.x.flags = 0x0002 r.x.ax = > 0x7143 Did 7143 really returned a different value in CX than 5700? They should return the same value for the same file. > One advantage of this is that it would be probably quicker on NT as it one > interrupt call and does not require any file handlers etc.... Yes. > Now for the hard question: > Which way should we go to fix utime? > Use 7143 or use SFN handles? My gut feel is to use the 7143 > function on Win2K where LFN is set. I agree. It might be a good idea to use 7143 on Windows 9X as well, with the current code as a fallback. > Not being up to date with NT 4.0 support and the LFN drivers/services what > would occur on NT 4.0? Should LFN bet set or not set? On NT4, LFN will be set only if the LFN driver is installed. > No flames please on the next question as I don't like asking, but it would > make the change easier to implement: Does NT 4.0 LFN support matter? IMHO it matters unless it's too tricky to support.