aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/event_buffer.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/event_buffer.c b/src/event_buffer.c
index 23e28c4..ea66a94 100644
--- a/src/event_buffer.c
+++ b/src/event_buffer.c
@@ -200,6 +200,7 @@ static int event_buffer_write(lua_State* L) {
} else if(lua_isuserdata(L, 2)) {
ret = evbuffer_write(buf->buffer, getSocketFd(L, 2));
} else {
+ ret = 0; /* Shush uninitialized warning */
luaL_argerror(L, 2, "Unexpected data type. Expects: integer/lightuserdata/socket");
}
lua_pushinteger(L, ret);
@@ -221,6 +222,7 @@ static int event_buffer_read(lua_State* L) {
} else if(lua_isuserdata(L, 2)) {
ret = evbuffer_read(buf->buffer, getSocketFd(L, 2), len);
} else {
+ ret = 0; /* Shush uninitialized warning */
luaL_argerror(L, 2, "Unexpected data type. Expects: integer/lightuserdata/socket");
}
lua_pushinteger(L, ret);