diff --git a/src/mod_cml_lua.c b/src/mod_cml_lua.c index daf15917..41b55436 100644 --- a/src/mod_cml_lua.c +++ b/src/mod_cml_lua.c @@ -67,6 +67,7 @@ static int cache_export_get_params(lua_State *L, int tbl, buffer *qrystr) { size_t i, len, klen = 0; char *key = NULL, *val = NULL; + if (buffer_string_is_empty(qrystr)) return 0; key = qrystr->ptr; /* we need the \0 */ diff --git a/src/mod_flv_streaming.c b/src/mod_flv_streaming.c index 90d980a4..cb6186f6 100644 --- a/src/mod_flv_streaming.c +++ b/src/mod_flv_streaming.c @@ -121,6 +121,7 @@ static int split_get_params(array *get_params, buffer *qrystr) { size_t is_key = 1, klen = 0; char *key = qrystr->ptr, *val = NULL; + if (buffer_string_is_empty(qrystr)) return 0; for (size_t i = 0, len = buffer_string_length(qrystr); i <= len; ++i) { switch(qrystr->ptr[i]) { case '=':