summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--managed.c5
2 files changed, 10 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 99e8b47..b11dd94 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2012-01-30 Gary Wong <gtw@gnu.org>
+
+ * managed.c (managed_property_change): Ignore invalid size increment
+ hints.
+
2010-11-09 Gary Wong <gtw@gnu.org>
* gwm.c (show_error) [USE_RANDR]: Show RANDR errors.
diff --git a/managed.c b/managed.c
index a510441..1e73513 100644
--- a/managed.c
+++ b/managed.c
@@ -589,6 +589,11 @@ extern void managed_property_change( struct gwm_window *window, int prop,
window->u.managed.width_inc = p32[ WM_NORMAL_HINTS_SIZE_INC_OFF ];
window->u.managed.height_inc =
p32[ WM_NORMAL_HINTS_SIZE_INC_OFF + 1 ];
+
+ if( window->u.managed.width_inc < 1 )
+ window->u.managed.width_inc = 1;
+ if( window->u.managed.height_inc < 1 )
+ window->u.managed.height_inc = 1;
}
if( p32[ WM_NORMAL_HINTS_FLAGS_OFF ] & WM_NORMAL_HINTS_ASPECT &&