summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>1997-11-12 04:40:52 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>1997-11-12 04:40:52 +0000
commit9b1e3331187d231ddff525bcea4bb095350e0a86 (patch)
treeb8d2b30064cdf5d68ca90b861be20da92a3ff313
parent4697fcee74ac522bd6ed4c9c512197a86cbce491 (diff)
TCSADRAIN -> TCSANOW. Using TCSADRAIN appears to cause a race condition
whereby the change is done with the wrong tcpgrp. This fixes suspending less/more when invoked in mail(1) or via sh -c "less somefile".
-rw-r--r--usr.bin/less/screen.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/less/screen.c b/usr.bin/less/screen.c
index 93149123ab4..5b3be8aead3 100644
--- a/usr.bin/less/screen.c
+++ b/usr.bin/less/screen.c
@@ -318,7 +318,7 @@ raw_mode(on)
*/
s = save_term;
}
- tcsetattr(2, TCSADRAIN, &s);
+ tcsetattr(2, TCSANOW, &s);
}
#else
#ifdef TCGETA