From 0a354ad0b2c9eaaa204c31db478da109dc6d2a8b Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Fri, 19 Apr 2024 19:20:02 +0200 Subject: Adding debian version 2:4.20.0+dfsg-1~exp1. Signed-off-by: Daniel Baumann --- ...-msg.sock-from-var-lib-samba-to-run-samba.patch | 55 ++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 debian/patches/move-msg.sock-from-var-lib-samba-to-run-samba.patch (limited to 'debian/patches/move-msg.sock-from-var-lib-samba-to-run-samba.patch') diff --git a/debian/patches/move-msg.sock-from-var-lib-samba-to-run-samba.patch b/debian/patches/move-msg.sock-from-var-lib-samba-to-run-samba.patch new file mode 100644 index 0000000..ceb2a4f --- /dev/null +++ b/debian/patches/move-msg.sock-from-var-lib-samba-to-run-samba.patch @@ -0,0 +1,55 @@ +From: Michael Tokarev +Date: Tue, 26 Apr 2022 16:11:48 +0300 +Subject: move msg.sock from /var/lib/samba to /run/samba + +This moves a socket directory from /var/lib/samba to /run/samba. + +https://lists.samba.org/archive/samba-technical/2022-April/137322.html + +diff --git a/source3/lib/messages.c b/source3/lib/messages.c +index 8641a9dad56..bf866e65e44 100644 +--- a/source3/lib/messages.c ++++ b/source3/lib/messages.c +@@ -461,11 +461,6 @@ static int messaging_context_destructor(struct messaging_context *ctx) + return 0; + } + +-static const char *private_path(const char *name) +-{ +- return talloc_asprintf(talloc_tos(), "%s/%s", lp_private_dir(), name); +-} +- + static NTSTATUS messaging_init_internal(TALLOC_CTX *mem_ctx, + struct tevent_context *ev, + struct messaging_context **pmsg_ctx) +@@ -500,7 +495,7 @@ static NTSTATUS messaging_init_internal(TALLOC_CTX *mem_ctx, + return NT_STATUS_ACCESS_DENIED; + } + +- priv_path = private_path("msg.sock"); ++ priv_path = lock_path(talloc_tos(), "msg.sock"); + if (priv_path == NULL) { + return NT_STATUS_NO_MEMORY; + } +@@ -663,7 +658,7 @@ NTSTATUS messaging_reinit(struct messaging_context *msg_ctx) + msg_ctx->per_process_talloc_ctx, + msg_ctx->event_ctx, + &msg_ctx->id.unique_id, +- private_path("msg.sock"), ++ lock_path(talloc_tos(), "msg.sock"), + lck_path, + messaging_recv_cb, + msg_ctx, +diff --git a/source4/lib/messaging/messaging.c b/source4/lib/messaging/messaging.c +index a00c35be0d5..da641bc06aa 100644 +--- a/source4/lib/messaging/messaging.c ++++ b/source4/lib/messaging/messaging.c +@@ -500,7 +500,7 @@ struct imessaging_context *imessaging_init(TALLOC_CTX *mem_ctx, + goto fail; + } + +- msg->sock_dir = lpcfg_private_path(msg, lp_ctx, "msg.sock"); ++ msg->sock_dir = lpcfg_lock_path(msg, lp_ctx, "msg.sock"); + if (msg->sock_dir == NULL) { + goto fail; + } -- cgit v1.2.3