Add sanity check.

SVN revision: 13667
This commit is contained in:
Kim Woelders 2005-03-09 23:06:43 +00:00
parent a0e9a9695d
commit 376d062e9b
1 changed files with 3 additions and 0 deletions

View File

@ -315,6 +315,9 @@ TextstateDrawText(TextState * ts, Window win, const char *text, int x, int y,
int textwidth_limit, offset_x, offset_y;
Pixmap drawable;
if (w <= 0 || h <= 0)
return;
TextStateLoadFont(ts);
/* Do encoding conversion, if necessary */