]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Author: Kieran Whitbread <k.j.whitbread@qmul.ac.uk>
authorAmos Jeffries <squid3@treenet.co.nz>
Thu, 11 Feb 2010 11:36:51 +0000 (00:36 +1300)
committerAmos Jeffries <squid3@treenet.co.nz>
Thu, 11 Feb 2010 11:36:51 +0000 (00:36 +1300)
Bug 2858: Segment violation in HTCP

src/htcp.cc

index 16fe186a0803c6f3367b26c0f2d0e7d1239e370c..4fabed191959269880e773f942a7150c9b6ce16a 100644 (file)
@@ -1298,6 +1298,13 @@ htcpHandleClr(htcpDataHeader * hdr, char *buf, int sz, struct sockaddr_in *from)
         return;
     }
 
+    if (!s->request) {
+        debugs(31, 2, "htcpHandleTstRequest: failed to parse request");
+        htcpLogHtcp(from, dhdr->opcode, LOG_UDP_INVALID, dash_str);
+        htcpFreeSpecifier(s);
+        return;
+    }
+
     if (!htcpAccessCheck(Config.accessList.htcp_clr, s, from))
     {
         debugs(31, 2, "htcpHandleClr: Access denied");