--- xscreensaver-5.11/hacks/xjack.c.small 2008-07-31 18:52:05.000000000 +0900
+++ xscreensaver-5.11/hacks/xjack.c 2010-07-26 02:33:17.000000000 +0900
@@ -62,6 +62,10 @@
st->rows--;
st->columns--;
+ /* If the window is stupidly small, just truncate. */
+ if (st->rows < 4) st->rows = 4;
+ if (st->columns < 12) st->columns = 12;
+
if (st->y > st->rows) st->y = st->rows-1;
if (st->x > st->columns) st->x = st->columns-2;
@@ -116,9 +120,12 @@
xjack_reshape (dpy, window, st, st->xgwa.width, st->xgwa.height);
- st->left = 0xFF & (random() % ((st->columns / 2)+1));
- st->right = st->left + (0xFF & (random() % (st->columns - st->left - 10)
+ if (st->columns >= 21)
+ {
+ st->left = 0xFF & (random() % ((st->columns / 2)+1));
+ st->right = st->left + (0xFF & (random() % (st->columns - st->left - 10)
+ 10));
+ }
st->x = 0;
st->y = 0;