Xref: utzoo comp.unix.programmer:1079 comp.unix.questions:28712 Path: utzoo!attcan!telly!lethe!torsqnt!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!wuarchive!mit-eddie!bloom-beacon!eru!hagbard!sunic!news.funet.fi!ousrvr!tolsun!clegg From: clegg@tolsun.oulu.fi (Matthew Tran Clegg/VTT) Newsgroups: comp.unix.programmer,comp.unix.questions Subject: How to restore terminal after curses program crashes? Keywords: curses,cbreak,terminal Message-ID: <1991Feb13.133332.22320@ousrvr.oulu.fi> Date: 13 Feb 91 13:33:32 GMT Sender: clegg@tolsun.oulu.fi (Matthew Clegg) Reply-To: clegg@tolsun.oulu.fi (Matthew Tran Clegg/VTT) Organization: University of Oulu, Finland Lines: 14 I've been working on a program that uses the curses package and cbreak mode. Once in a while, a bug will cause the program to crash (for example, with a segmentation fault). This completely unhinges the terminal. It won't respond to anything anymore, except if I press ^C, then the csh prompt will be printed. (I've noticed sometimes that nethack will crash in this way too, but only when the game is better than any I've had in months -- a real bummer.) Does anyone know how to restore the terminal to a sane state? So far, the only thing that has worked for me is the power switch :-). Matthew Clegg clegg@tolsun.oulu.fi, February 13