delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/1998/08/23/10:12:48

Date: Sun, 23 Aug 1998 17:12:05 +0300 (IDT)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: Nate Eldredge <nate AT cartsys DOT com>
cc: "John M. Aldrich" <fighteer AT cs DOT net>, Michel de Ruiter <mdruiter AT cs DOT vu DOT nl>,
djgpp-workers AT delorie DOT com
Subject: Re: stat c:/con
In-Reply-To: <35DF22AA.7761E41C@cartsys.com>
Message-ID: <Pine.SUN.3.91.980823170827.1451V-100000@is>
MIME-Version: 1.0

On Sat, 22 Aug 1998, Nate Eldredge wrote:

> I think I see the problem.  In order to get the execute bit right,
> `stat' calls `_is_executable' on any file which isn't a directory
> (directories have the execute bit set, Unix-style).  See line 600 or so
> of stat.c.

stat.c is not supposed to get to line 600 when it is called on a
device.  It detects devices on line 477 and returns to the caller on
line 509 (these line numbers are from the latest alpha of v2.02).  As
far as I could see, this is so since v2.01 at least.

The problem is, DOS 7 seems to have broken the feature whereby 
`_truename' returns "x:/foo" (yes, with a forward slash) for any device 
`foo'.  And `stat' relies on that to detect devices.  Damn you, Bill from 
Redmond!

I will need to think how to repair that without rewriting large portions 
of `stat'.  If a small change won't do that, I'd prefer to leave this at 
that, since nobody has complained yet.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019