From: Jaroslav Kysela Date: Mon, 23 May 2016 18:44:17 +0000 (+0200) Subject: http: coverity - fix hc_access assignment when freed X-Git-Tag: v4.2.1~491 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=c55cef96390649ff14e1a42cb9666db4dbf834bd;p=thirdparty%2Ftvheadend.git http: coverity - fix hc_access assignment when freed --- diff --git a/src/http.c b/src/http.c index d98a06fae..6a0ecabe3 100644 --- a/src/http.c +++ b/src/http.c @@ -844,8 +844,10 @@ http_access_verify(http_connection_t *hc, int mask) if (res) { access_destroy(hc->hc_access); - if (http_verify_prepare(hc, &v)) + if (http_verify_prepare(hc, &v)) { + hc->hc_access = NULL; return -1; + } hc->hc_access = access_get((struct sockaddr *)hc->hc_peer, hc->hc_username, http_verify_callback, &v); http_verify_free(&v);