www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1996/04/16/14:03:43

Date: Tue, 16 Apr 1996 20:54:44 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: Jih-Shin Ho <u7711501 AT bicmos DOT ee DOT nctu DOT edu DOT tw>
Cc: djgpp AT delorie DOT com
Subject: Re: Detecting drives
In-Reply-To: <4ku08f$mej@ccnews.nctu.edu.tw>
Message-Id: <Pine.SUN.3.91.960416204807.6630K-100000@is>
Mime-Version: 1.0

On 15 Apr 1996, Jih-Shin Ho wrote:

> The above code can detect all drives that DOS understands. For example,
> network drive.

Not so fast.  "Network drives" might mean Novell 3.x, and you'd be 
surprised to see what you can get there, since Novell 3.x hooks Int 21h 
before DOS and thus any info about Novell drives bypasses DOS entirely.

> 0x4409 DOS function call doesn't touch disk drive. It uses (I am not sure) the
> internal data structure in DOS kernel for the detection.

This might be a source of another problem, this time with CD-ROMs.  You
could get successfull return from 4409 with stale data even if there is no
disk in the drive.  That's because no DOS filesystem exists on the CD,
it's an illusion created entirely by MSCDEX.  Try putting a disk into a CD
drive, make some DOS call, then remove the disk, close the door and issue
4409.  I've seen similar functions returning ``valid'' data about a disk
that's long ago gone in such cases (but I didn't try this with 4409, so I
can't say for sure). 

- Raw text -


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