graph: check width value (FS#465)

Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
Julien Danjou 2009-03-02 14:20:08 +01:00
parent e81fd419c3
commit ab0220274e
1 changed files with 1 additions and 1 deletions

View File

@ -505,7 +505,7 @@ luaA_graph_newindex(lua_State *L, awesome_token_t token)
break; break;
case A_TK_WIDTH: case A_TK_WIDTH:
width = luaL_checknumber(L, 3); width = luaL_checknumber(L, 3);
if(width != d->width) if(width >= 2 && width != d->width)
{ {
d->width = width; d->width = width;
d->size = d->width - 2; d->size = d->width - 2;