Return 0 on setfscreatecon(3) failure, like set_selinux_file_context(). --- lib/selinux.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/selinux.c b/lib/selinux.c index e31a5f92..a2ea91c8 100644 --- a/lib/selinux.c +++ b/lib/selinux.c @@ -94,7 +94,7 @@ int reset_selinux_file_context (void) } if (selinux_enabled) { if (setfscreatecon_raw (NULL) != 0) { - return 1; + return security_getenforce () != 0; } } return 0; -- 2.31.0