[SCM] Samba Shared Repository - branch master updated
Volker Lendecke
vlendec at samba.org
Fri Dec 25 12:21:03 UTC 2015
The branch, master has been updated
via d4c2395 smbd: do not disable "store dos attributes" on-the-fly
from 5b1a87e dsdb subnets: warn when an IPv6 address is in IPv4 embedding range
https://git.samba.org/?p=samba.git;a=shortlog;h=master
- Log -----------------------------------------------------------------
commit d4c2395e6428312854b8570064bddab3a7f188ff
Author: Uri Simchoni <uri at samba.org>
Date: Thu Dec 24 08:10:11 2015 +0200
smbd: do not disable "store dos attributes" on-the-fly
Smbd would disable "store dos attributes" on-the-fly if the
attempt to set/get user.DOSATTRIB fails with ENOTSUP or ENOSYS.
The rationale behind it was that the file system does not support
extended attributes, so there's no need to fill up the log with
failure messages.
However, a "wide symlink" could point to a spot that doesn't support
extended attributes. Even with the default banned wide links, we
currenly allow stat'ing those files and follow the symlink, and this
in turn would disable "store dos attributes" for the whole share.
The user.DOSATTRIB attribute also stores file creation time,
so that is also affected.
Another case where this behavior would turn storage of DOS attributes
off is that of the ".." entry at the root of the share, if the parent
folder for the share's root path does not support extended attributes.
On the other hand, the information on the file system and its support
of extended attributes is readily available, so the fix for explosion
of the log should be not to configure "store dos attributes" on
such a share.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=11649
Signed-off-by: Uri Simchoni <uri at samba.org>
Reviewed-by: Volker Lendecke <vl at samba.org>
Autobuild-User(master): Volker Lendecke <vl at samba.org>
Autobuild-Date(master): Fri Dec 25 13:20:58 CET 2015 on sn-devel-144
-----------------------------------------------------------------------
Summary of changes:
source3/include/proto.h | 1 -
source3/param/loadparm.c | 11 -----------
source3/smbd/dosmode.c | 30 ++++++------------------------
3 files changed, 6 insertions(+), 36 deletions(-)
Changeset truncated at 500 lines:
diff --git a/source3/include/proto.h b/source3/include/proto.h
index 4cd69fd..cc00a84 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -1067,7 +1067,6 @@ uint32_t lp_get_spoolss_state( void );
struct smb_signing_state;
bool lp_use_sendfile(int snum, struct smb_signing_state *signing_state);
void set_use_sendfile(int snum, bool val);
-void set_store_dos_attributes(int snum, bool val);
void lp_set_mangling_method(const char *new_method);
bool lp_posix_pathnames(void);
void lp_set_posix_pathnames(void);
diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c
index 348298d..9f4a2b4 100644
--- a/source3/param/loadparm.c
+++ b/source3/param/loadparm.c
@@ -4262,17 +4262,6 @@ void set_use_sendfile(int snum, bool val)
sDefault._use_sendfile = val;
}
-/*******************************************************************
- Turn off storing DOS attributes if this share doesn't support it.
-********************************************************************/
-
-void set_store_dos_attributes(int snum, bool val)
-{
- if (!LP_SNUM_OK(snum))
- return;
- ServicePtrs[(snum)]->store_dos_attributes = val;
-}
-
void lp_set_mangling_method(const char *new_method)
{
lpcfg_string_set(Globals.ctx, &Globals.mangling_method, new_method);
diff --git a/source3/smbd/dosmode.c b/source3/smbd/dosmode.c
index 0996007..942d286 100644
--- a/source3/smbd/dosmode.c
+++ b/source3/smbd/dosmode.c
@@ -279,18 +279,9 @@ static bool get_ea_dos_attribute(connection_struct *conn,
SAMBA_XATTR_DOS_ATTRIB, attrstr,
sizeof(attrstr));
if (sizeret == -1) {
- if (errno == ENOSYS
-#if defined(ENOTSUP)
- || errno == ENOTSUP) {
-#else
- ) {
-#endif
- DEBUG(1,("get_ea_dos_attribute: Cannot get attribute "
- "from EA on file %s: Error = %s\n",
- smb_fname_str_dbg(smb_fname),
- strerror(errno)));
- set_store_dos_attributes(SNUM(conn), False);
- }
+ DBG_INFO("get_ea_dos_attribute: Cannot get attribute "
+ "from EA on file %s: Error = %s\n",
+ smb_fname_str_dbg(smb_fname), strerror(errno));
return False;
}
@@ -422,18 +413,9 @@ static bool set_ea_dos_attribute(connection_struct *conn,
files_struct *fsp = NULL;
if((errno != EPERM) && (errno != EACCES)) {
- if (errno == ENOSYS
-#if defined(ENOTSUP)
- || errno == ENOTSUP) {
-#else
- ) {
-#endif
- DEBUG(1,("set_ea_dos_attributes: Cannot set "
- "attribute EA on file %s: Error = %s\n",
- smb_fname_str_dbg(smb_fname),
- strerror(errno) ));
- set_store_dos_attributes(SNUM(conn), False);
- }
+ DBG_INFO("set_ea_dos_attributes: Cannot set "
+ "attribute EA on file %s: Error = %s\n",
+ smb_fname_str_dbg(smb_fname), strerror(errno));
return false;
}
--
Samba Shared Repository
More information about the samba-cvs
mailing list