svn commit: samba r7694 - in trunk/source/smbd: .
jra at samba.org
jra at samba.org
Fri Jun 17 15:54:16 GMT 2005
Author: jra
Date: 2005-06-17 15:54:13 +0000 (Fri, 17 Jun 2005)
New Revision: 7694
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=7694
Log:
Fix from James Peach @ SGI for null pointer ACL free.
Jeremy.
Modified:
trunk/source/smbd/posix_acls.c
Changeset:
Modified: trunk/source/smbd/posix_acls.c
===================================================================
--- trunk/source/smbd/posix_acls.c 2005-06-17 15:54:10 UTC (rev 7693)
+++ trunk/source/smbd/posix_acls.c 2005-06-17 15:54:13 UTC (rev 7694)
@@ -2949,7 +2949,9 @@
return 0;
/* Case (2). */
- if ((uid == current_user.uid) && (user_has_privileges(current_user.nt_user_token,&se_take_ownership))) {
+ if (lp_enable_privileges() &&
+ (uid == current_user.uid) &&
+ (user_has_privileges(current_user.nt_user_token,&se_take_ownership))) {
become_root();
/* Keep the current file gid the same - take ownership doesn't imply group change. */
ret = SMB_VFS_CHOWN(conn, fname, uid, (gid_t)-1);
@@ -3970,7 +3972,9 @@
done:
- SMB_VFS_SYS_ACL_FREE_ACL(conn, posix_acl);
+ if (posix_acl) {
+ SMB_VFS_SYS_ACL_FREE_ACL(conn, posix_acl);
+ }
DEBUG(10,("check_posix_acl_group_write: file %s returning (ret = %d).\n", fname, ret ));
return ret;
More information about the samba-cvs
mailing list