Mail Archives: djgpp/1998/10/15/01:18:19
Goh Yong Kwang wrote:
> My program always terminate when the user presses CTRL-C. Files go unsaved, data are lost and sometimes corrupted because it was terminated halfway through writing files and so on.
>
> I think there's a way to handle this situation whereby the program maintains control after CTRL-C is pressed.
>
> >From what I know, I think I've to implement some sort of CTRL-C handler/function/routine but I've totally no idea how to do it. Can anyone help me with this?
Create you handler function for SIGINT and install it using signal()
See __djgpp_set_ctr_c() and signal().
--
Dim Zegebart
Moscow, Russia
- Raw text -