Message-Id: Date: Mon, 18 Mar 96 12:35 MST From: mat AT ardi DOT com (Mat Hostetter) To: Eli Zaretskii Subject: Re: `stat' fails to detect nonexistent files under WinNT In-Reply-To: References: cc: djgpp-workers AT delorie DOT com >>>>> "Eli" == Eli Zaretskii writes: Eli> To test the above, you might take stat.c from the library Eli> sources and compile it with -DTEST. It will produce an Eli> executable test program which you should invoke thusly: Eli> stat 0 file ... Eli> (0 is the value of the bit-mapped variable `_djstat_flags' Eli> that controls the behavior of `stat'; it is documented in the Eli> library on-line docs). The program will then stat each of Eli> the files from the command line and print (most of) the Eli> contents of `struct stat', together with a human-readable Eli> description of the bits set in `_djstat_fail_bits'. Please Eli> post the info so that I could isolate the problem (I don't Eli> have access to a WinNT machine). Here you go. This is from WinNT 3.51. Neither badfile nor reallylongfilename.will.fail exist. C:\tmp>stat 0 badfile reallylongfilename.will.fail DOS 5.0 (Microsoft MS-DOS) badfile: 2 1 50444 1 42 0 312768000 Fri Nov 30 00:00:00 1979 Everything checks out OK reallylongfilename.will.fail: lossage : No such file or directory (ENOENT) Get TrueName call (INT 21h/AX=6000h) failed Could this all be explained by Kenji Masaki's idea: I use WinNT 3.51 on NTFS , and gets same result. It seems that WinNT dose not support undocumented DOS call int 21h ax=6000h . -Mat