Xref: utzoo comp.unix.programmer:1099 comp.unix.questions:28787 Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!ora!jerry From: jerry@ora.com (Jerry Peek) Newsgroups: comp.unix.programmer,comp.unix.questions Subject: Re: How to restore terminal after curses program crashes? Summary: One-character command name might be better Keywords: curses,cbreak,terminal Message-ID: <1991Feb16.115209.15927@ora.com> Date: 16 Feb 91 11:52:09 GMT References: <1991Feb13.133332.22320@ousrvr.oulu.fi> <1991Feb14.192959.22939@dartvax.dartmouth.edu> Organization: O'Reilly and Associates Inc., Cambridge, MA Lines: 21 In article <1991Feb14.192959.22939@dartvax.dartmouth.edu> andyb@coat.com (Andy Behrens) writes: > clegg@tolsun.oulu.fi (Matthew Tran Clegg/VTT) writes: > > 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). > > Typing > ctrl-J reset ctrl-J > should fix everything. Once in a while I've had a session wedged bad enough that *each* character I type is treated as a new command. After this happened a few times, I made the following symbolic link in my bin directory: ln -s /usr/ucb/reset ] It makes a single-character command called "]" that does a "reset". You should be able to use a single-character name for the other fixes people have posted here, too. --Jerry Peek, O'Reilly & Associates, Inc. jerry@ora.com +1 617 354-5800