[SCM] Samba Shared Repository - branch master updated

Jeremy Allison jra at samba.org
Tue Aug 9 20:05:01 UTC 2022


The branch, master has been updated
       via  4d015b4b6db smbstatus: Fix the 32-bit build on FreeBSD
       via  b1b513eebb0 smbd: Use dirfsp where we have it
      from  d6490bdc0f6 s3:passdb: Remove unused function secrets_fetch_trust_account_password()

https://git.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 4d015b4b6db20235d6d821204d03b0e1fce1c681
Author: Volker Lendecke <vl at samba.org>
Date:   Tue Aug 9 12:42:05 2022 +0200

    smbstatus: Fix the 32-bit build on FreeBSD
    
    Signed-off-by: Volker Lendecke <vl at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>
    
    Autobuild-User(master): Jeremy Allison <jra at samba.org>
    Autobuild-Date(master): Tue Aug  9 20:04:26 UTC 2022 on sn-devel-184

commit b1b513eebb0999cdfabab597927305be7d978605
Author: Volker Lendecke <vl at samba.org>
Date:   Mon Aug 8 14:05:46 2022 +0200

    smbd: Use dirfsp where we have it
    
    One reference to conn->cwd_fsp less, makes "mkdir" look less ugly in
    strace.
    
    Signed-off-by: Volker Lendecke <vl at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

-----------------------------------------------------------------------

Summary of changes:
 source3/smbd/open.c         |  2 +-
 source3/utils/status_json.c | 10 ++++++----
 2 files changed, 7 insertions(+), 5 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/smbd/open.c b/source3/smbd/open.c
index d39d2d619cd..f1c2f7382bc 100644
--- a/source3/smbd/open.c
+++ b/source3/smbd/open.c
@@ -4329,7 +4329,7 @@ static NTSTATUS mkdir_internal(connection_struct *conn,
 	 */
 	fsp->fsp_flags.is_pathref = true;
 
-	status = fd_openat(conn->cwd_fsp, smb_dname, fsp, &how);
+	status = fd_openat(parent_dir_fname->fsp, smb_fname_atname, fsp, &how);
 	if (!NT_STATUS_IS_OK(status)) {
 		return status;
 	}
diff --git a/source3/utils/status_json.c b/source3/utils/status_json.c
index 69b31e27f54..e2798e3e392 100644
--- a/source3/utils/status_json.c
+++ b/source3/utils/status_json.c
@@ -75,7 +75,8 @@ static int add_server_id_to_json(struct json_object *parent_json,
 		goto failure;
 	}
 
-	pid_str = talloc_asprintf(tmp_ctx, "%lu", server_id.pid);
+	pid_str = talloc_asprintf(
+		tmp_ctx, "%lu", (unsigned long)server_id.pid);
 	result = json_add_string(&sub_json, "pid", pid_str);
 	if (result < 0) {
 		goto failure;
@@ -90,7 +91,8 @@ static int add_server_id_to_json(struct json_object *parent_json,
 	if (result < 0) {
 		goto failure;
 	}
-	unique_id_str = talloc_asprintf(tmp_ctx, "%lu", server_id.unique_id);
+	unique_id_str = talloc_asprintf(
+		tmp_ctx, "%"PRIu64, server_id.unique_id);
 	result = json_add_string(&sub_json, "unique_id", unique_id_str);
 	if (result < 0) {
 		goto failure;
@@ -834,7 +836,7 @@ static int add_open_to_json(struct json_object *parent_json,
 	if (result < 0) {
 		goto failure;
 	}
-	share_file_id = talloc_asprintf(tmp_ctx, "%lu", e->share_file_id);
+	share_file_id = talloc_asprintf(tmp_ctx, "%"PRIu64, e->share_file_id);
 	result = json_add_string(&sub_json, "share_file_id", share_file_id);
 	if (result < 0) {
 		goto failure;
@@ -871,7 +873,7 @@ static int add_open_to_json(struct json_object *parent_json,
 	}
 
 	pid = server_id_str_buf(e->pid, &tmp);
-	key = talloc_asprintf(tmp_ctx, "%s/%lu", pid, e->share_file_id);
+	key = talloc_asprintf(tmp_ctx, "%s/%"PRIu64, pid, e->share_file_id);
 	result = json_add_object(&opens_json, key, &sub_json);
 	if (result < 0) {
 		goto failure;


-- 
Samba Shared Repository



More information about the samba-cvs mailing list