svn commit: samba r16202 - in branches/SAMBA_3_0/source/libsmb: .

jra at samba.org jra at samba.org
Tue Jun 13 18:15:03 GMT 2006


Author: jra
Date: 2006-06-13 18:15:03 +0000 (Tue, 13 Jun 2006)
New Revision: 16202

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=16202

Log:
Fix Klocwork #3. Strange - was already fixed in HEAD.
Jeremy.

Modified:
   branches/SAMBA_3_0/source/libsmb/asn1.c


Changeset:
Modified: branches/SAMBA_3_0/source/libsmb/asn1.c
===================================================================
--- branches/SAMBA_3_0/source/libsmb/asn1.c	2006-06-13 18:09:37 UTC (rev 16201)
+++ branches/SAMBA_3_0/source/libsmb/asn1.c	2006-06-13 18:15:03 UTC (rev 16202)
@@ -268,17 +268,22 @@
 	}
 
 	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--;
 		}



More information about the samba-cvs mailing list