sowm

An itsy bitsy floating window manager (220~ sloc!).
git clone git://mfeller.io/sowm.git
Log | Files | Refs | README | LICENSE

commit e478fcf515519303674e580efc5bef9cb4099c27
parent cfdaadc71a9f781c2d65a3d908d760d0b90e6d0d
Author: Dylan Araps <dylan.araps@gmail.com>
Date:   Sat, 12 Oct 2019 18:48:53 +0300

make sowm crash when a window is resized to 0px big.

Diffstat:
Msowm.c | 5++---
1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/sowm.c b/sowm.c @@ -10,7 +10,6 @@ #include <signal.h> #include <unistd.h> -#define MAX(a, b) ((a) > (b) ? (a) : (b)) #define TABLENGTH(X) (sizeof(X)/sizeof(*X)) typedef union { @@ -276,8 +275,8 @@ void notify_motion(XEvent *e) { XMoveResizeWindow(dis, start.subwindow, attr.x + (start.button==1 ? xdiff : 0), attr.y + (start.button==1 ? ydiff : 0), - MAX(1, attr.width + (start.button==3 ? xdiff : 0)), - MAX(1, attr.height + (start.button==3 ? ydiff : 0))); + attr.width + (start.button==3 ? xdiff : 0), + attr.height + (start.button==3 ? ydiff : 0)); } }