File nfs-utils-nfsdctl-fix-lockd-config-during-autostart.patch of Package nfs-utils
From c5b1a81310471927f0f42ae9b592c6e06ceb2793 Mon Sep 17 00:00:00 2001
From: Scott Mayhew <smayhew@redhat.com>
Date: Tue, 6 May 2025 10:53:14 -0400
Subject: [PATCH] nfsdctl: fix lockd config during autostart
Be sure to actually send the lockd config values over the netlink
interface.
While we're at it, get rid of the unused "ret" variable.
Fixes: f61c2ff8 ("nfsdctl: add necessary bits to configure lockd")
Reviewed-by: Jeff Layton <jlayton@kernel.org>
Signed-off-by: Scott Mayhew <smayhew@redhat.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
---
utils/nfsdctl/nfsdctl.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/utils/nfsdctl/nfsdctl.c b/utils/nfsdctl/nfsdctl.c
index 1fdbb44daf51..c2e342607a6e 100644
--- a/utils/nfsdctl/nfsdctl.c
+++ b/utils/nfsdctl/nfsdctl.c
@@ -1417,7 +1417,6 @@ static int lockd_configure(struct nl_sock *sock, int grace)
{
char *tcp_svc, *udp_svc;
int tcpport = 0, udpport = 0;
- int ret;
tcp_svc = conf_get_str("lockd", "port");
if (tcp_svc) {
@@ -1432,6 +1431,8 @@ static int lockd_configure(struct nl_sock *sock, int grace)
if (udpport < 0)
return 1;
}
+
+ return lockd_config_doit(sock, LOCKD_CMD_SERVER_SET, grace, tcpport, udpport);
}
static int
--
2.50.1