| delorie.com/archives/browse.cgi | search |
| Date: | Wed, 25 Jun 2003 12:49:47 +0300 |
| From: | "Eli Zaretskii" <eliz AT elta DOT co DOT il> |
| Sender: | halo1 AT zahav DOT net DOT il |
| To: | dkaufman AT rahul DOT net |
| Message-Id: | <2950-Wed25Jun2003124946+0300-eliz@elta.co.il> |
| X-Mailer: | emacs 21.3.50 (via feedmail 8 I) and Blat ver 1.8.9 |
| CC: | djgpp AT delorie DOT com |
| In-reply-to: | <bdbdie$im7$1@blue.rahul.net> (message from Doug Kaufman on Wed, |
| 25 Jun 2003 05:56:30 +0000 (UTC)) | |
| Subject: | Re: stat and character devices |
| References: | <bdbdie$im7$1 AT blue DOT rahul DOT net> |
| Reply-To: | djgpp AT delorie DOT com |
| Errors-To: | nobody AT delorie DOT com |
| X-Mailing-List: | djgpp AT delorie DOT com |
| X-Unsubscribes-To: | listserv AT delorie DOT com |
> From: Doug Kaufman <dkaufman AT rahul DOT net>
> Newsgroups: comp.os.msdos.djgpp
> Date: Wed, 25 Jun 2003 05:56:30 +0000 (UTC)
>
> I noticed that stat treats some character devices differently, depending
> on whether it is run in a DOS box under Win98 or in plain DOS. The COM
> series (com1, com2, etc.) shows as a character device when run under
> plain DOS, but not in the DOS box under Win98.
On my Windows 98 box, "ls -l com2" shows "com2" in yellow, which means
`stat' did return the character-device bit set for it. So I guess I
cannot reproduce this here.
> A test program that demonstrates this follows.
You didn't show the results of running this program on Windows 98.
Here are mine:
The value of base is com1
The value of st_dev is -1.
The value of st_mode is 8612.
The file is a character device.
Exactly as I'd expect.
So I guess more digging is required.
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |