rc-selinux: access check was backwards

This commit is contained in:
Jason Zaman 2016-03-06 16:22:51 +08:00 committed by William Hubbs
parent 3b5a8b331e
commit 3fa9015b8e

View File

@ -370,7 +370,7 @@ void selinux_setup(char **argv)
* which will open the pty with initrc_devpts_t, if it doesnt exist,
* fall back to plain exec
*/
if (access("/usr/sbin/open_init_pty", X_OK)) {
if (!access("/usr/sbin/open_init_pty", X_OK)) {
if (execvp("/usr/sbin/open_init_pty", argv)) {
perror("execvp");
exit(-1);