NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

bin/46002: Remove unused variable.



>Number:         46002
>Category:       bin
>Synopsis:       Remove unused variable.
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    bin-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Feb 12 11:55:00 +0000 2012
>Originator:     Henning Petersen
>Release:        NetBSD-current
>Organization:
>Environment:
>Description:
Remove unused variable.
Found by cppcheck.
>How-To-Repeat:

>Fix:
diff -u -p -r1.118 print.c
--- bin/ps/print.c      13 Jun 2011 03:42:15 -0000      1.118
+++ bin/ps/print.c      11 Jan 2012 18:10:00 -0000
@@ -554,13 +554,12 @@ void
 lstate(void *arg, VARENT *ve, int mode)
 {
        struct kinfo_lwp *k;
-       int flag, is_zombie;
+       int flag;
        char *cp;
        VAR *v;
        char buf[16];
 
        k = arg;
-       is_zombie = 0;
        v = ve->var;
        flag = k->l_flag;
        cp = buf;
@@ -590,7 +589,6 @@ lstate(void *arg, VARENT *ve, int mode)
        case LSZOMB:
        case LSDEAD:
                *cp = 'Z';
-               is_zombie = 1;
                break;
 
        case LSSUSPENDED:



Home | Main Index | Thread Index | Old Index