diff options
author | Jeremy Allison <jra@samba.org> | 2006-06-13 18:15:03 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 11:17:25 -0500 |
commit | 319f80bbf0455cfaf80eab51313a56db4ed04ac5 (patch) | |
tree | 433072c8b3ef36a0b7edd53c4c0671e0ed943886 /source/libsmb/asn1.c | |
parent | b369d0891afe8b777b837eaac317131232568ca7 (diff) | |
download | samba-319f80bbf0455cfaf80eab51313a56db4ed04ac5.tar.gz samba-319f80bbf0455cfaf80eab51313a56db4ed04ac5.tar.xz samba-319f80bbf0455cfaf80eab51313a56db4ed04ac5.zip |
r16202: Fix Klocwork #3. Strange - was already fixed in HEAD.
Jeremy.
Diffstat (limited to 'source/libsmb/asn1.c')
-rw-r--r-- | source/libsmb/asn1.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/source/libsmb/asn1.c b/source/libsmb/asn1.c index 072fd302830..86a28451927 100644 --- a/source/libsmb/asn1.c +++ b/source/libsmb/asn1.c @@ -268,17 +268,22 @@ BOOL asn1_start_tag(ASN1_DATA *data, uint8 tag) } if (!asn1_read_uint8(data, &b)) { + SAFE_FREE(nesting); return False; } if (b & 0x80) { int n = b & 0x7f; - if (!asn1_read_uint8(data, &b)) + if (!asn1_read_uint8(data, &b)) { + SAFE_FREE(nesting); return False; + } nesting->taglen = b; while (n > 1) { - if (!asn1_read_uint8(data, &b)) + if (!asn1_read_uint8(data, &b)) { + SAFE_FREE(nesting); return False; + } nesting->taglen = (nesting->taglen << 8) | b; n--; } |