Skip to content
Snippets Groups Projects
Commit da38a17a authored by Andy Green's avatar Andy Green
Browse files

coverity 188321: reject wsi with NULL vhost earlier

parent ea8c44d7
No related branches found
No related tags found
No related merge requests found
......@@ -383,7 +383,10 @@ lws_http_serve(struct lws *wsi, char *uri, const char *origin,
int n;
wsi->handling_404 = 0;
if (wsi->vhost && wsi->vhost->error_document_404 &&
if (!wsi->vhost)
return -1;
if (wsi->vhost->error_document_404 &&
!strcmp(uri, wsi->vhost->error_document_404))
wsi->handling_404 = 1;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment