Message ID | alpine.LRH.2.20.1702081835250.9813@namei.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c index c7c6619..d98550a 100644 --- a/security/selinux/hooks.c +++ b/security/selinux/hooks.c @@ -5887,7 +5887,7 @@ static int selinux_setprocattr(struct task_struct *p, return error; /* Obtain a SID for the context, if one was specified. */ - if (size && str[1] && str[1] != '\n') { + if (size && str[0] && str[0] != '\n') { if (str[size-1] == '\n') { str[size-1] = 0; size--;