aboutsummarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorEon S. Jeon2013-12-17 12:45:38 -0500
committerRoberto E. Vargas Caballero2013-12-18 08:11:22 +0100
commit761dfdc98f578b35aaf0c5928e1cad74257e4cf1 (patch)
treed078a65cfd7992e0f001a67dc70778497e38435f
parent8f8fec23f0fcec27304313272551cc715645e6c4 (diff)
downloadaur-761dfdc98f578b35aaf0c5928e1cad74257e4cf1.tar.gz
Prevent resizing stdin
This fixes a bug that the parent tty gets resized whenever you launch st through command line. The problem was that ioctl was resizing cmdfd before it gets initialized in ttynew. Since cmdfd is a global variable, its initial value is 0, and consequently stdin was being resized.
-rw-r--r--st.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/st.c b/st.c
index f883ac15bf47..4fb331196ac9 100644
--- a/st.c
+++ b/st.c
@@ -3667,11 +3667,11 @@ run(void) {
}
}
+ ttynew();
if(!xw.isfixed)
cresize(w, h);
else
cresize(xw.fw, xw.fh);
- ttynew();
gettimeofday(&lastblink, NULL);
gettimeofday(&last, NULL);