sherman@speech2.cs.cmu.edu (Andrew Sherman) (10/23/85)
After using the v option(go to editor) and coming back to less prompt line get put at the top of the screen, erasing one line. Anybody else had this problem and figured out how to fix it?? drew (I don't know what to put down here so I'll just say) sherman@cmu-cs-speech2
cook@speech2.cs.cmu.edu (James Cook) (10/24/85)
What he meant to say was: When the v option (go into editor) is invoked, one can edit the file with no problems; but when one exits the editor less gets confused. Less puts the prompt line on the first line of the screen and beeps at any command. Does anyone know how to fix this? Jim Cook cook@cmu-cs-speech2.arpa
mark@nsc-pdc.UUCP (Mark Nudelman) (10/29/85)
> What he meant to say was: > > When the v option (go into editor) is invoked, one can edit the file with > no problems; but when one exits the editor less gets confused. Less puts the > prompt line on the first line of the screen and beeps at any command. Two different bugs are being discussed here. The first is that a subcommand invoked from less (like vi from "v" or a shell command from "!") cannot be suspended with ^Z. (This applies only to BSD versions.) My fix is to replace the lsystem() function in signal.c with the code at the end of this message. The other bug is the one mentioned in the quote above: less gets confused after returning from vi. I can't produce this behavior, so if anyone has seen this bug, I'd like to know what system it was running on (BSD, System V, etc) and what type of terminal you were using. Also, if possible, details as to exactly what keystrokes produce what kinds of misbehavior. Mark Nudelman ihnp4!nsc!nsc-pdc!mark National Semiconductor tektronix!reed!nsc-pdc!mark ---------- start of replacement for lsystem() function -------------- lsystem(cmd) char *cmd; { lower_left(); clear_eol(); puts("!"); puts(cmd); puts("\n"); deinit(); flush(); raw_mode(0); SIGNAL(SIGINT, SIG_DFL); #ifdef SIGTSTP SIGNAL(SIGTSTP, SIG_DFL); #endif system(cmd); init_signals(); raw_mode(1); init(); } ---------- end of replacement for lsystem() function --------------