The branch, master has been updated via cbe80ceef85 smbd: don't free smb_fname_parent in unix_mode() via 8c254d84bad smbd: remove dead code from ce0e96e6f48 Add net-ads-join dnshostname=fqdn option
https://git.samba.org/?p=samba.git;a=shortlog;h=master - Log ----------------------------------------------------------------- commit cbe80ceef85fad0655a0708b3884edea04a75590 Author: Ralph Boehme <s...@samba.org> Date: Fri May 29 11:44:28 2020 +0200 smbd: don't free smb_fname_parent in unix_mode() The TALLOC_FREEs should have been removed as part of 45a560bce3ef06c211e60e3932521303cc396896. Sorry! Signed-off-by: Ralph Boehme <s...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> Autobuild-User(master): Jeremy Allison <j...@samba.org> Autobuild-Date(master): Fri May 29 20:02:55 UTC 2020 on sn-devel-184 commit 8c254d84bad560dae575b41a27b1d39e67b65fb9 Author: Ralph Boehme <s...@samba.org> Date: Fri May 29 11:27:35 2020 +0200 smbd: remove dead code LINKS_READ_ONLY is not defined anywhere since ages. Signed-off-by: Ralph Boehme <s...@samba.org> Reviewed-by: Jeremy Allison <j...@samba.org> ----------------------------------------------------------------------- Summary of changes: source3/smbd/dosmode.c | 15 --------------- 1 file changed, 15 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/smbd/dosmode.c b/source3/smbd/dosmode.c index 40633b8996e..4012d6e64c9 100644 --- a/source3/smbd/dosmode.c +++ b/source3/smbd/dosmode.c @@ -84,17 +84,6 @@ static uint32_t filter_mode_by_protocol(uint32_t mode) return mode; } -static int set_link_read_only_flag(const SMB_STRUCT_STAT *const sbuf) -{ -#ifdef S_ISLNK -#if LINKS_READ_ONLY - if (S_ISLNK(sbuf->st_mode) && S_ISDIR(sbuf->st_mode)) - return FILE_ATTRIBUTE_READONLY; -#endif -#endif - return 0; -} - /**************************************************************************** Change a dos mode to a unix mode. Base permission for files: @@ -139,7 +128,6 @@ mode_t unix_mode(connection_struct *conn, int dosmode, DBG_ERR("stat failed [%s]: %s\n", smb_fname_str_dbg(smb_fname_parent), strerror(errno)); - TALLOC_FREE(smb_fname_parent); return(0); /* *** shouldn't happen! *** */ } @@ -149,7 +137,6 @@ mode_t unix_mode(connection_struct *conn, int dosmode, smb_fname_str_dbg(smb_fname), (int)dir_mode)); /* Clear "result" */ result = 0; - TALLOC_FREE(smb_fname_parent); } if (IS_DOS_DIR(dosmode)) { @@ -239,8 +226,6 @@ static uint32_t dos_mode_from_sbuf(connection_struct *conn, if (S_ISDIR(smb_fname->st.st_ex_mode)) result = FILE_ATTRIBUTE_DIRECTORY | (result & FILE_ATTRIBUTE_READONLY); - result |= set_link_read_only_flag(&smb_fname->st); - dos_mode_debug_print(__func__, result); return result; -- Samba Shared Repository