URL:
https://github.com/SSSD/sssd/pull/165
Title: #165: selinux: Do not fail if SELinux is not managed
lslebodn commented:
"""
if you do not want to use following pattern
```
if (ret != somerrror) { //mostly ENOENT
//ignore this err
ret = EOK
} else (ret != EOK)
//log error and fail
}
```
and you prefer to return ERR_SELINUX_NOT_MANAGED.
Then please update debug message after `get_seuser` in `seuser_needs_update`.
Because internal error code are diffigult to read.
e.g.
```
(Mon Apr 3 15:08:11 2017) [[sssd[selinux_child[1702]]]] [main] (0x0400): performing
selinux operations
(Mon Apr 3 15:08:11 2017) [[sssd[selinux_child[1702]]]] [sss_semanage_init] (0x0400):
SELinux policy not managed
(Mon Apr 3 15:08:11 2017) [[sssd[selinux_child[1702]]]] [seuser_needs_update] (0x2000):
get_seuser: ret: 1432158258 seuser: unknown mls: unknown
```
"""
See the full comment at
https://github.com/SSSD/sssd/pull/165#issuecomment-291181014