From 2774b6d0021db426c334c643de07d28faf0517af Mon Sep 17 00:00:00 2001 From: Michael Drake Date: Thu, 8 Jul 2010 17:23:46 +0000 Subject: Don't try to plot bitmaps at 0 width or height. svn path=/trunk/libnsfb/; revision=10613 --- src/plot/16bpp.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/plot/16bpp.c') diff --git a/src/plot/16bpp.c b/src/plot/16bpp.c index 84aa813..028e453 100644 --- a/src/plot/16bpp.c +++ b/src/plot/16bpp.c @@ -473,6 +473,9 @@ bitmap(nsfb_t *nsfb, int height = loc->y1 - loc->y0; nsfb_bbox_t clipped; /* clipped display */ + if (width == 0 || height == 0) + return true; + /* Scaled bitmaps are handled by a separate function */ if (width != bmp_width || height != bmp_height) return bitmap_scaled(nsfb, loc, pixel, bmp_width, bmp_height, -- cgit v1.2.3