Author: jra
Date: 2006-06-28 04:59:58 +0000 (Wed, 28 Jun 2006)
New Revision: 16615

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

Log:
Klocwork #2025. Stop null deref. I actually don't
think this can happen in real life but the code is
too complicated to be sure....
Jerry please merge this for 3.0.23.
Jeremy.

Modified:
   trunk/source/smbd/posix_acls.c


Changeset:
Modified: trunk/source/smbd/posix_acls.c
===================================================================
--- trunk/source/smbd/posix_acls.c      2006-06-28 04:56:23 UTC (rev 16614)
+++ trunk/source/smbd/posix_acls.c      2006-06-28 04:59:58 UTC (rev 16615)
@@ -1483,7 +1483,7 @@
                 * Only add to the file ACL if not inherit only.
                 */
 
-               if (!(psa->flags & SEC_ACE_FLAG_INHERIT_ONLY)) {
+               if (current_ace && !(psa->flags & SEC_ACE_FLAG_INHERIT_ONLY)) {
                        DLIST_ADD_END(file_ace, current_ace, tmp_ace);
 
                        /*

Reply via email to