svn commit: samba r20840 - in branches: SAMBA_3_0/source/smbd
SAMBA_3_0_24/source/smbd
jra at samba.org
jra at samba.org
Tue Jan 16 20:32:40 GMT 2007
Author: jra
Date: 2007-01-16 20:32:39 +0000 (Tue, 16 Jan 2007)
New Revision: 20840
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=20840
Log:
Keep removing the old BOOL ok logic.
Jeremy.
Modified:
branches/SAMBA_3_0/source/smbd/reply.c
branches/SAMBA_3_0_24/source/smbd/reply.c
Changeset:
Modified: branches/SAMBA_3_0/source/smbd/reply.c
===================================================================
--- branches/SAMBA_3_0/source/smbd/reply.c 2007-01-16 18:26:02 UTC (rev 20839)
+++ branches/SAMBA_3_0/source/smbd/reply.c 2007-01-16 20:32:39 UTC (rev 20840)
@@ -3677,11 +3677,15 @@
BOOL rmdir_internals(connection_struct *conn, const char *directory)
{
- BOOL ok;
+ int ret;
SMB_STRUCT_STAT st;
- ok = (SMB_VFS_RMDIR(conn,directory) == 0);
- if(!ok && ((errno == ENOTEMPTY)||(errno == EEXIST)) && lp_veto_files(SNUM(conn))) {
+ ret = SMB_VFS_RMDIR(conn,directory);
+ if (ret == 0) {
+ return True;
+ }
+
+ if(((errno == ENOTEMPTY)||(errno == EEXIST)) && lp_veto_files(SNUM(conn))) {
/*
* Check to see if the only thing in this directory are
* vetoed files/directories. If so then delete them and
@@ -3744,12 +3748,12 @@
}
CloseDir(dir_hnd);
/* Retry the rmdir */
- ok = (SMB_VFS_RMDIR(conn,directory) == 0);
+ ret = SMB_VFS_RMDIR(conn,directory);
}
err:
- if (!ok) {
+ if (ret != 0) {
DEBUG(3,("rmdir_internals: couldn't remove directory %s : "
"%s\n", directory,strerror(errno)));
return False;
Modified: branches/SAMBA_3_0_24/source/smbd/reply.c
===================================================================
--- branches/SAMBA_3_0_24/source/smbd/reply.c 2007-01-16 18:26:02 UTC (rev 20839)
+++ branches/SAMBA_3_0_24/source/smbd/reply.c 2007-01-16 20:32:39 UTC (rev 20840)
@@ -3676,11 +3676,15 @@
BOOL rmdir_internals(connection_struct *conn, const char *directory)
{
- BOOL ok;
+ int ret;
SMB_STRUCT_STAT st;
- ok = (SMB_VFS_RMDIR(conn,directory) == 0);
- if(!ok && ((errno == ENOTEMPTY)||(errno == EEXIST)) && lp_veto_files(SNUM(conn))) {
+ ret = SMB_VFS_RMDIR(conn,directory);
+ if (ret == 0) {
+ return True;
+ }
+
+ if(((errno == ENOTEMPTY)||(errno == EEXIST)) && lp_veto_files(SNUM(conn))) {
/*
* Check to see if the only thing in this directory are
* vetoed files/directories. If so then delete them and
@@ -3743,12 +3747,12 @@
}
CloseDir(dir_hnd);
/* Retry the rmdir */
- ok = (SMB_VFS_RMDIR(conn,directory) == 0);
+ ret = SMB_VFS_RMDIR(conn,directory);
}
err:
- if (!ok) {
+ if (ret != 0) {
DEBUG(3,("rmdir_internals: couldn't remove directory %s : "
"%s\n", directory,strerror(errno)));
return False;
More information about the samba-cvs
mailing list