1
0
Fork 0
util-linux/debian/patches/upstream-stable/lsns-enhance-compilation-without-USE_NS_GET_API.patch
Daniel Baumann 070ab789ab
Adding debian version 2.41-5.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
2025-06-21 11:26:36 +02:00

36 lines
1.2 KiB
Diff

From: Karel Zak <kzak@redhat.com>
Date: Tue, 1 Apr 2025 14:36:36 +0200
Subject: lsns: enhance compilation without USE_NS_GET_API
- Move add_namespace_for_nsfd() declaration to the #ifdef block
(based on c62ed3d58602fd29fe12085f7caf03761ed91b81)
References: 2ced43400f35f7bd45b29364e04166a63a06e16a
Signed-off-by: Karel Zak <kzak@redhat.com>
---
sys-utils/lsns.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/sys-utils/lsns.c b/sys-utils/lsns.c
index 4c49a8b..fc590f8 100644
--- a/sys-utils/lsns.c
+++ b/sys-utils/lsns.c
@@ -304,6 +304,9 @@ static inline const struct colinfo *get_column_info(unsigned num)
}
#ifdef USE_NS_GET_API
+static struct lsns_namespace *add_namespace_for_nsfd(struct lsns *ls, int fd, ino_t ino);
+
+
/* Get the inode number for the parent namespace of the namespace `fd' specifies.
* If `pfd' is non-null, the file descriptor opening the parent namespace.*/
static int get_parent_ns_ino(int fd, enum lsns_type lsns_type, ino_t *pino, int *pfd)
@@ -422,8 +425,6 @@ error:
return rc;
}
-static struct lsns_namespace *add_namespace_for_nsfd(struct lsns *ls, int fd, ino_t ino);
-
static struct lsns_namespace *get_namespace(struct lsns *ls, ino_t ino)
{
struct list_head *p;