summary refs log tree commit diff
path: root/bin/ptee.c
diff options
context:
space:
mode:
authorC. McEnroe <june@causal.agency>2021-10-18 13:52:12 -0400
committerC. McEnroe <june@causal.agency>2021-10-18 13:52:12 -0400
commit813352679a1feafb8e43b51e45edeaf4abcb3f98 (patch)
tree2559e4255b24c11ca93a266bdf3d635d2b14651f /bin/ptee.c
parentAdd shotty -i to output inline colors (diff)
downloadsrc-813352679a1feafb8e43b51e45edeaf4abcb3f98.tar.gz
src-813352679a1feafb8e43b51e45edeaf4abcb3f98.zip
Swap functions of ^Q and ^S in ptee
Diffstat (limited to '')
-rw-r--r--bin/ptee.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/bin/ptee.c b/bin/ptee.c
index 6a9a16b..f2ea960 100644
--- a/bin/ptee.c
+++ b/bin/ptee.c
@@ -78,12 +78,12 @@ int main(int argc, char *argv[]) {
 			ssize_t rlen = read(STDIN_FILENO, buf, sizeof(buf));
 			if (rlen < 0) err(EX_IOERR, "read");
 
-			if (rlen == 1 && buf[0] == CTRL('S')) {
+			if (rlen == 1 && buf[0] == CTRL('Q')) {
 				stop ^= true;
 				continue;
 			}
 
-			if (rlen == 1 && buf[0] == CTRL('Q')) {
+			if (rlen == 1 && buf[0] == CTRL('S')) {
 				char dump[] = "\x1B[10i";
 				ssize_t wlen = write(STDOUT_FILENO, dump, sizeof(dump) - 1);
 				if (wlen < 0) err(EX_IOERR, "write");