delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/1998/04/27/04:37:11

Sender: vheyndri AT rug DOT ac DOT be
Message-Id: <35444366.1F64@rug.ac.be>
Date: Mon, 27 Apr 1998 10:35:50 +0200
From: Vik Heyndrickx <Vik DOT Heyndrickx AT rug DOT ac DOT be>
Mime-Version: 1.0
To: djgpp-workers AT delorie DOT com
Subject: compatibility issues with BIOS functions

Hi w AT d DOT c's,

Some user reported keyboard problems with RHIDE. It wouldn't read the
keyboard properly and RHIDE showed truly erratic behaviour. After
removing the KBDBUF.SYS driver from config.sys everything works as it
would with most of us.
I haven't really searched why this fails with RHIDE, but I have a good
idea. 
I think RHIDE is peeking into BIOS area to see whether a keystroke is
available and read it afterwards using the BIOS function of interrupt
0x16. That is potentially dangerous since device drivers can alter the
functioning of the BIOS.
The libc functions work the same way. I propose to replace any
references to the BIOS data area with interrupt calls to int 0x16. That
may be a little slower, but at least it assures compatibility. Any
thoughts?
The problem may also have been caused by mixed BIOS and DOS calls, i.e.
using the BIOS to test whether a key is available and read it afterwards
from the console through DOS.
I think this may occur with kbhit vs. getch, but I need to check this.

-- 
 \ Vik /-_-_-_-_-_-_/
  \___/ Heyndrickx /
   \ /-_-_-_-_-_-_/  Knight in the Order of the Unsigned Types

- Raw text -


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