diff options
author | Nicholas Marriott <nicholas.marriott@gmail.com> | 2008-09-29 16:58:02 +0000 |
---|---|---|
committer | Nicholas Marriott <nicholas.marriott@gmail.com> | 2008-09-29 16:58:02 +0000 |
commit | 9d6827ebb22b34e0ecf20c483a81a09ad814a5ca (patch) | |
tree | 9ee9a6cd39f2e10a58a42d5b649b460b689d7432 /screen.c | |
parent | 8132b4d092838f1864d05b39b11986193731b967 (diff) | |
download | rtmux-9d6827ebb22b34e0ecf20c483a81a09ad814a5ca.tar.gz rtmux-9d6827ebb22b34e0ecf20c483a81a09ad814a5ca.tar.bz2 rtmux-9d6827ebb22b34e0ecf20c483a81a09ad814a5ca.zip |
UINT_MAX.
Diffstat (limited to 'screen.c')
-rw-r--r-- | screen.c | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -1,4 +1,4 @@ -/* $Id: screen.c,v 1.73 2008-09-26 06:45:26 nicm Exp $ */ +/* $Id: screen.c,v 1.74 2008-09-29 16:58:02 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net> @@ -93,6 +93,9 @@ screen_resize_x(struct screen *s, u_int sx) const struct grid_cell *gc; u_int xx, yy; + if (sx == 0) + fatalx("zero size"); + /* If getting larger, not much to do. */ if (sx > screen_size_x(s)) { gd->sx = sx; @@ -129,6 +132,9 @@ screen_resize_y(struct screen *s, u_int sy) struct grid_data *gd = s->grid; u_int oy, yy, ny; + if (sy == 0) + fatalx("zero size"); + /* Size decreasing. */ if (sy < screen_size_y(s)) { oy = screen_size_y(s); |