delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/1996/03/20/04:49:32

Date: Wed, 20 Mar 1996 11:46:04 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: "Alexander V. Lukyanov" <lav AT video DOT yars DOT free DOT net>
Cc: djgpp-workers AT delorie DOT com
Subject: Re: gdb info
In-Reply-To: <199603191837.VAA06399@video.yars.free.net>
Message-Id: <Pine.SUN.3.91.960320113921.22801B@is>
Mime-Version: 1.0

On Tue, 19 Mar 1996, Alexander V. Lukyanov wrote:

> > >  _truename returns nonzero.  canon_path is:
> > >
> > >  C:\tmp\BADFILE
> 
> Seems that truename returns error for invalid file names (such as a.b.c,
> which is invalid for FAT volume) and no error for valid but nonexistent files.
> Is it a correct behavior?

Yes, it is.  The underlying DOS call and the command TRUENAME available
from the DOS prompt (you can try it and see) do not require that the file
exists, just that the drive is valid and the filename is legal.  The 
purpose of that call is not to chack if the file exists, but to produce a 
fully qualified pathname.  You might need it e.g. in the case that you 
want to create a new file, therefore it doesn't require that the file 
already exists.

> I think check for ff_name matching original file name will be sufficient.
> It also may be reazonably to check for being label only for files residing
> in root directory. (labels usually reside there, isn't it?)

See the patch I mailed today.  If you can test-drive it on any unusual 
disk types, please do.

- Raw text -


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