coverity 181574: confirm uri_ptr non-null before deref

This commit is contained in:
Andy Green 2017-07-19 14:19:03 +08:00
parent 3c360d5192
commit 1690581cd2

View file

@ -777,7 +777,7 @@ lws_http_action(struct lws *wsi)
/* we insist on absolute paths */ /* we insist on absolute paths */
if (uri_ptr[0] != '/') { if (!uri_ptr || uri_ptr[0] != '/') {
lws_return_http_status(wsi, HTTP_STATUS_FORBIDDEN, NULL); lws_return_http_status(wsi, HTTP_STATUS_FORBIDDEN, NULL);
goto bail_nuke_ah; goto bail_nuke_ah;