From 5476665ba2d92b42cf732dcf7dfbbb82d317d35d Mon Sep 17 00:00:00 2001 From: Julien Danjou Date: Sun, 26 Apr 2009 19:43:54 +0200 Subject: [PATCH] button: return 0 on index with unknown elem Signed-off-by: Julien Danjou --- button.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/button.c b/button.c index e2cc652c..fc4cea86 100644 --- a/button.c +++ b/button.c @@ -194,7 +194,7 @@ luaA_button_index(lua_State *L) lua_pushnumber(L, button->button); break; default: - break; + return 0; } return 1;