mirror of
https://github.com/clearlinux/uwsgi.git
synced 2026-09-06 21:51:30 +00:00
plugins/lua: check return value of uwsgi_response_prepare_headers
Reported by Coverity as CID #1100802
This commit is contained in:
@@ -798,7 +798,8 @@ static int uwsgi_lua_request(struct wsgi_request *wsgi_req) {
|
||||
// send status
|
||||
if (lua_type(L, -3) == LUA_TSTRING || lua_type(L, -3) == LUA_TNUMBER) {
|
||||
http = lua_tolstring(L, -3, &slen);
|
||||
uwsgi_response_prepare_headers(wsgi_req, (char *) http, slen);
|
||||
if (uwsgi_response_prepare_headers(wsgi_req, (char *) http, slen))
|
||||
return -1;
|
||||
}
|
||||
else {
|
||||
uwsgi_log("[uwsgi-lua] invalid response status !!!\n");
|
||||
|
||||
Reference in New Issue
Block a user