svn commit: samba r14219 - in branches/SAMBA_3_0/source/rpc_parse: .

jra at samba.org jra at samba.org
Sat Mar 11 23:11:25 GMT 2006


Author: jra
Date: 2006-03-11 23:11:24 +0000 (Sat, 11 Mar 2006)
New Revision: 14219

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

Log:
Fix coverity #135. Don't deref a ptr if it can be NULL.
Jeremy.

Modified:
   branches/SAMBA_3_0/source/rpc_parse/parse_misc.c


Changeset:
Modified: branches/SAMBA_3_0/source/rpc_parse/parse_misc.c
===================================================================
--- branches/SAMBA_3_0/source/rpc_parse/parse_misc.c	2006-03-11 23:10:31 UTC (rev 14218)
+++ branches/SAMBA_3_0/source/rpc_parse/parse_misc.c	2006-03-11 23:11:24 UTC (rev 14219)
@@ -908,7 +908,7 @@
 
 void init_unistr2_w(TALLOC_CTX *ctx, UNISTR2 *str, const smb_ucs2_t *buf)
 {
-	uint32 len = strlen_w(buf);
+	uint32 len = buf ? strlen_w(buf) : 0;
 
 	ZERO_STRUCTP(str);
 



More information about the samba-cvs mailing list