]> git.armaanb.net Git - st.git/blobdiff - st.c
bump version to 0.8.1
[st.git] / st.c
diff --git a/st.c b/st.c
index 543c6150a6aeb5229d0995371166f367bd7a362d..46c954ba8bc7276168cfd0129b8e6526b1591715 100644 (file)
--- a/st.c
+++ b/st.c
@@ -13,6 +13,7 @@
 #include <sys/select.h>
 #include <sys/types.h>
 #include <sys/wait.h>
+#include <termios.h>
 #include <unistd.h>
 #include <wchar.h>
 
@@ -460,7 +461,7 @@ selextend(int col, int row, int type, int done)
 {
        int oldey, oldex, oldsby, oldsey, oldtype;
 
-       if (!sel.mode)
+       if (sel.mode == SEL_IDLE)
                return;
        if (done && sel.mode == SEL_EMPTY) {
                selclear();
@@ -739,7 +740,6 @@ sigchld(int a)
        exit(0);
 }
 
-
 void
 stty(char **args)
 {
@@ -761,7 +761,7 @@ stty(char **args)
        }
        *q = '\0';
        if (system(cmd) != 0)
-           perror("Couldn't call stty");
+               perror("Couldn't call stty");
 }
 
 int
@@ -1693,7 +1693,6 @@ csihandle(void)
                tputtab(csiescseq.arg[0]);
                break;
        case 'J': /* ED -- Clear screen */
-               selclear();
                switch (csiescseq.arg[0]) {
                case 0: /* below */
                        tclearregion(term.c.x, term.c.y, term.col-1, term.c.y);