Skip to contentSkip to conversation

docs: fix context_*_range (3) return value documentation

PATCH In review Rahul Sandhu 2 participants 3 messages Oct 3, 2025 – Oct 7, 2025 SELinux security module

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 docs: fix context_*_range (3) return value documentation

The context_*_range () family of functions return less than zero on failure[1][2].

[1] https://github.com/SELinuxProject/selinux/blob/main/libselinux/src/context.c#L184
[2] https://github.com/SELinuxProject/selinux/blob/main/libselinux/src/context.c#L190

---
 libselinux/man/man3/context_new.3 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
libselinux/man/man3/context_new.3 +1 -1
index 3dabac3d..04522366 100644
@@ -71,7 +71,7 @@ set a context component.
 .SH "RETURN VALUE"
 On failure
 .BR context_*_set ()
-functions return non-zero and 0 on success.
+functions return non-zero on failure and 0 on success.
 
 The other functions return NULL on failure and non-NULL on success.
 
Signature · 1 line
2.50.1
maintainer Acked-by on v1 1/1
#1 lore raw
Quoted 8 lines · Rahul Sandhu

The context_*_range () family of functions return less than zero on failure[1][2].

[1] https://github.com/SELinuxProject/selinux/blob/main/libselinux/src/context.c#L184
[2] https://github.com/SELinuxProject/selinux/blob/main/libselinux/src/context.c#L190

Quoted 21 lines
---
 libselinux/man/man3/context_new.3 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
libselinux/man/man3/context_new.3 +1 -2
index 3dabac3d..04522366 100644
@@ -71,7 +71,7 @@ set a context component.
 .SH "RETURN VALUE"
 On failure
 .BR context_*_set ()
-functions return non-zero and 0 on success.
+functions return non-zero on failure and 0 on success.
 
 The other functions return NULL on failure and non-NULL on success.
 
--

2.50.1

maintainer
#2 lore raw
Quoted 6 lines · Stephen Smalley
Quoted 4 lines · Rahul Sandhu

The context_*_range () family of functions return less than zero on failure[1][2].

Quoted 6 lines
Quoted 4 lines

[1] https://github.com/SELinuxProject/selinux/blob/main/libselinux/src/context.c#L184
[2] https://github.com/SELinuxProject/selinux/blob/main/libselinux/src/context.c#L190

Thanks, merged.