svn commit: samba r5606 - in trunk/source/smbd: .
jra at samba.org
jra at samba.org
Tue Mar 1 21:25:53 GMT 2005
Author: jra
Date: 2005-03-01 21:25:53 +0000 (Tue, 01 Mar 2005)
New Revision: 5606
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=5606
Log:
Fix for bug #2399 - ensure we use SMB_VFS_STAT instead of stat
when checking for existance of a pathname.
Jeremy.
Modified:
trunk/source/smbd/service.c
Changeset:
Modified: trunk/source/smbd/service.c
===================================================================
--- trunk/source/smbd/service.c 2005-03-01 17:28:25 UTC (rev 5605)
+++ trunk/source/smbd/service.c 2005-03-01 21:25:53 UTC (rev 5606)
@@ -278,6 +278,7 @@
*user = 0;
fstrcpy(dev, pdev);
+ ZERO_STRUCT(st);
if (NT_STATUS_IS_ERR(*status = share_sanity_checks(snum, dev))) {
return NULL;
@@ -622,7 +623,7 @@
}
#else
/* the alternative is just to check the directory exists */
- if (stat(conn->connectpath, &st) != 0 || !S_ISDIR(st.st_mode)) {
+ if (SMB_VFS_STAT(conn, conn->connectpath, &st) != 0 || !S_ISDIR(st.st_mode)) {
DEBUG(0,("'%s' does not exist or is not a directory, when connecting to [%s]\n", conn->connectpath, lp_servicename(SNUM(conn))));
change_to_root_user();
yield_connection(conn, lp_servicename(SNUM(conn)));
More information about the samba-cvs
mailing list