summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAurélien Aptel2011-06-09 14:27:07 +0200
committerAurélien Aptel2011-06-09 14:27:07 +0200
commitcddbd6eee59104a029087c30f9ff5e7e415bc584 (patch)
tree5c9c8a8bca16c7487f304ea3d3d0bdbe6b33313d
parent3959a99293785e603270d8798fbe0cb2ba0ae0ee (diff)
downloadst-cddbd6eee59104a029087c30f9ff5e7e415bc584.tar.gz
st-cddbd6eee59104a029087c30f9ff5e7e415bc584.tar.xz
st-cddbd6eee59104a029087c30f9ff5e7e415bc584.zip
fix segfault with mouse selection. (thx anonymous)
-rw-r--r--st.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/st.c b/st.c
index b331ead..df8353a 100644
--- a/st.c
+++ b/st.c
@@ -615,7 +615,7 @@ bmotion(XEvent *e) {
if(oldey != sel.ey || oldex != sel.ex) {
int starty = MIN(oldey, sel.ey);
int endy = MAX(oldey, sel.ey);
- drawregion(0, (starty > 0 ? starty : 0), term.col, (sel.ey < term.row ? endy+1 : term.row));
+ drawregion(0, (starty > 0 ? starty : 0), term.col, (endy < term.row ? endy+1 : term.row));
}
}
}