From: Carsten Otte Date: Sat, 25 Mar 2006 11:08:22 +0000 (-0800) Subject: [PATCH] remove needless check in binfmt_elf.c X-Git-Tag: v2.6.17-rc1~750 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=55148548124e3e52e8921f1cb0e325111ef9cbb1;p=linux-2.6 [PATCH] remove needless check in binfmt_elf.c Local variable i is unsigned int and thus cannot be negative. (akpm: unsigneds shouldn't be called `i'. This value cannot possibly be negative anyway). Signed-off-by: Carsten Otte Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/fs/binfmt_elf.c b/fs/binfmt_elf.c index 61c21e7dc9..4349113881 100644 --- a/fs/binfmt_elf.c +++ b/fs/binfmt_elf.c @@ -1334,7 +1334,7 @@ static int fill_psinfo(struct elf_prpsinfo *psinfo, struct task_struct *p, i = p->state ? ffz(~p->state) + 1 : 0; psinfo->pr_state = i; - psinfo->pr_sname = (i < 0 || i > 5) ? '.' : "RSDTZW"[i]; + psinfo->pr_sname = (i > 5) ? '.' : "RSDTZW"[i]; psinfo->pr_zomb = psinfo->pr_sname == 'Z'; psinfo->pr_nice = task_nice(p); psinfo->pr_flag = p->flags;