From 250296dd22ae4344acd73807fda64451febef786 Mon Sep 17 00:00:00 2001 From: Mark Andrews Date: Thu, 29 Nov 2012 18:11:05 +1100 Subject: [PATCH] initialize the octet string to empty so that we don't free garbage on error --- lib/dns/spnego.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/dns/spnego.c b/lib/dns/spnego.c index d70130bb24..4136cbb020 100644 --- a/lib/dns/spnego.c +++ b/lib/dns/spnego.c @@ -1000,6 +1000,9 @@ decode_octet_string(const unsigned char *p, size_t len, int e; size_t slen; + k->data = NULL; + k->length = 0; + e = der_match_tag(p, len, ASN1_C_UNIV, PRIM, UT_OctetString, &l); if (e) return (e);