Mail Archives: djgpp-workers/2001/01/06/06:44:34
From: "Eli Zaretskii" <eliz AT is DOT elta DOT co DOT il>
> > From: "Norberto Alfredo Bensa" <ceo AT nbensacomputers DOT com>
> > Date: Fri, 5 Jan 2001 21:48:08 -0300
> >
> > I've moved the CD-ROM calls down to the "one_more_try" part of the code,
> > just before 213600.
> [snip]
> > if (0x07 <= dos_version /* Is FAT32 supported? */
> > && 0x0a != dos_version) /* OS/2 doesn't support FAT32 */
> > {
> > /* 217303 - Win9x - Get Extended Free Drive Space:
>
> Are we sure that CD-ROMs and DVDs support FAT32 calls? If not, I
> think we should not issue FAT32 calls for CDs and DVDs. At least for
> a CD, you can know that it's a CD with this snippet:
>
> > regs.x.ax = 0x150b; /* is this drive supported by CD-ROM driver?
*/
> > regs.x.cx = drive_number;
> > __dpmi_int(0x2f, ®s);
> > if ((regs.x.flags & 1) == 0 && regs.x.bx == 0xadad && regs.x.ax !=
0)
> > {
What about DVDs? Is a DVD-ROM recognized as a CD-ROM, i.e. will the above
code be true if it is a DVD-ROM or it will be false?
Martin, can you please test the following?
#include <stdio.h>
#include <dos.h>
int main (void)
{
if (_is_cdrom_drive ( 'R' - 'A' +1 ))
{
printf ("is a CDROM\n");
}
else
{
printf ("not a CD-ROM\n");
}
}
What does print if you test with a DVD-ROM in your R: drive?
Regards,
Norberto
- Raw text -