do not print empty text

This commit is contained in:
Julien Danjou 2007-10-15 12:42:48 +02:00
parent 4a7acf821e
commit b3995c6152
1 changed files with 1 additions and 1 deletions

2
draw.c
View File

@ -37,7 +37,7 @@ drawtext(Display *disp, int screen, int x, int y, int w, int h, Drawable drawabl
XftDraw *xftdrawable; XftDraw *xftdrawable;
drawrectangle(disp, screen, x, y, w, h, drawable, dw, dh, True, color[ColBG]); drawrectangle(disp, screen, x, y, w, h, drawable, dw, dh, True, color[ColBG]);
if(!text) if(!a_strlen(text))
return; return;
olen = len = a_strlen(text); olen = len = a_strlen(text);
if(len >= sizeof(buf)) if(len >= sizeof(buf))