summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrey Nazarov <skuller@skuller.net>2012-03-19 14:30:09 +0400
committerAndrey Nazarov <skuller@skuller.net>2012-04-03 01:25:48 +0400
commit5462d7fe9c560e40ffce865d236b9ccdb00d9b11 (patch)
treec1e2e0c9da82989fc1e7df0ed8a54b2c221ed09b
parentdb1e0f1b36fd2a8056f042a580066cb396245bde (diff)
Ignore empty arguments to R_DrawFill.
-rw-r--r--src/gl_draw.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gl_draw.c b/src/gl_draw.c
index 15a5cdb..ab21098 100644
--- a/src/gl_draw.c
+++ b/src/gl_draw.c
@@ -239,11 +239,15 @@ void R_TileClear(int x, int y, int w, int h, qhandle_t pic)
void R_DrawFill8(int x, int y, int w, int h, int c)
{
+ if (!w || !h)
+ return;
_GL_StretchPic(x, y, w, h, 0, 0, 1, 1, d_8to24table[c & 0xff], TEXNUM_WHITE, 0);
}
void R_DrawFill32(int x, int y, int w, int h, uint32_t color)
{
+ if (!w || !h)
+ return;
_GL_StretchPic(x, y, w, h, 0, 0, 1, 1, color, TEXNUM_WHITE, 0);
}