🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.ibm.pc.programmer
Article #815

Re: Avoiding ^C

#815
From: Cay Horstmann
Date: Sat, 30 Jun 1990 20:37
29 lines
1892 bytes
In article <577@dg.dg.com> bruce@archive.rtp.dg.com (Bruce Kahn) writes:
>In article <10688@spool.cs.wisc.edu>, so@brownie.cs.wisc.edu (Bryan So) writes:
>|> I have tried to trap the Ctrl-Break and Ctrl-C interrupts by
>|> "signal", "ctrlbrk" in Turbo C and installing my own 0x23 handler.
>|> But there seems to be no way to prevent "^C" from printing out to
>|> the screen.  Can somebody explain a way to do it?  Thanks.
>|> 
>|> Bryan
>
>  The only way that Ive found to prevent the annoying ^C from being displayed
>is to NOT use the standard printf calls.  I found that I had to issue direct
>BIOS write calls and bypass DOS.  The reason being (I was told a long long
>time ago) that DOS allows you to insert your own INT23 handler but it stil
>sets a 'break' flag internally and when it does any screen I/O it checks the
>flag; if it is set it inserts a ^C into the buffer and clears the flag.
>  If you need more specifics I can dig out my code and tell you what exactly I
>did (it may have been I issued INT21, AH=10H calls myself)...
>
>					Bruce (bruce@archive.rtp.dg.com)

I don't think this is true. Software which I wrote and which runs in
graphics mode (with no calls to printf whatsoever) but homegrown
put-the-pixels-to-the-screen routines for all I/O still shows the
(expletive deleted) ^C, even though I (of course) remap the Ctrl-Brk|C
handlers. 

I'd love to know what to do about this. 

Cay
Technical Details
Message-ID: <1990Jun30.203726.7480@sjsumcs.sjsu.edu>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!cs.utexas.edu!samsung!usc!apple!vsi1!octopus!sjsumcs!horstman
References: <10688@spool.cs.wisc.edu> <577@dg.dg.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!cs.utexas.edu!samsung!usc!apple!vsi1!octopus!sjsumcs!horstman
From: horstman@sjsumcs.sjsu.edu (Cay Horstmann)
Newsgroups: comp.sys.ibm.pc.programmer
Subject: Re: Avoiding ^C
Message-ID: <1990Jun30.203726.7480@sjsumcs.sjsu.edu>
Date: 30 Jun 90 20:37:26 GMT
References: <10688@spool.cs.wisc.edu> <577@dg.dg.com>
Reply-To: horstman@sjsumcs.SJSU.EDU (Cay Horstmann)
Organization: San Jose State University
Lines: 29