svn commit: samba r13981 - branches/SAMBA_3_0/source/auth trunk/source/auth

vlendec at samba.org vlendec at samba.org
Tue Mar 7 20:14:48 GMT 2006


Author: vlendec
Date: 2006-03-07 20:14:47 +0000 (Tue, 07 Mar 2006)
New Revision: 13981

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

Log:
Fix Coverity bug # 138
Modified:
   branches/SAMBA_3_0/source/auth/auth_util.c
   trunk/source/auth/auth_util.c


Changeset:
Modified: branches/SAMBA_3_0/source/auth/auth_util.c
===================================================================
--- branches/SAMBA_3_0/source/auth/auth_util.c	2006-03-07 19:52:26 UTC (rev 13980)
+++ branches/SAMBA_3_0/source/auth/auth_util.c	2006-03-07 20:14:47 UTC (rev 13981)
@@ -76,7 +76,7 @@
 	DEBUG(5,("attempting to make a user_info for %s (%s)\n", internal_username, smb_name));
 
 	*user_info = SMB_MALLOC_P(auth_usersupplied_info);
-	if (!user_info) {
+	if (*user_info == NULL) {
 		DEBUG(0,("malloc failed for user_info (size %lu)\n", (unsigned long)sizeof(*user_info)));
 		return NT_STATUS_NO_MEMORY;
 	}

Modified: trunk/source/auth/auth_util.c
===================================================================
--- trunk/source/auth/auth_util.c	2006-03-07 19:52:26 UTC (rev 13980)
+++ trunk/source/auth/auth_util.c	2006-03-07 20:14:47 UTC (rev 13981)
@@ -76,7 +76,7 @@
 	DEBUG(5,("attempting to make a user_info for %s (%s)\n", internal_username, smb_name));
 
 	*user_info = SMB_MALLOC_P(auth_usersupplied_info);
-	if (!user_info) {
+	if (*user_info == NULL) {
 		DEBUG(0,("malloc failed for user_info (size %lu)\n", (unsigned long)sizeof(*user_info)));
 		return NT_STATUS_NO_MEMORY;
 	}



More information about the samba-cvs mailing list