lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 16 Apr 2009 23:22:21 +0530
From:	Sukanto Ghosh <sukanto.cse.iitb@...il.com>
To:	trivial@...nel.org
Cc:	linux-kernel@...r.kernel.org
Subject: [PATCH] removes unused variable from kernel/sysctl.h

This patch removes the unused variable 'val' from the
__do_proc_dointvec() function
in kernel/sysctl.h. The integer has been declared and used as 'val =
-val' and there is
no reference to it anywhere.
Although I am this doesn't affects the kernel binary because gcc
removes it, still it
might be confusing for people reading the code.


Signed-off-by: Sukanto Ghosh <sukanto.cse.iitb@...il.com>

----

--- linux-2.6.29.1/kernel/sysctl.c.orig 2009-04-16 19:57:21.000000000 +0530
+++ linux-2.6.29.1/kernel/sysctl.c      2009-04-16 19:58:26.000000000 +0530
@@ -2198,7 +2198,7 @@ static int __do_proc_dointvec(void *tbl_
                  void *data)
 {
 #define TMPBUFLEN 21
-       int *i, vleft, first=1, neg, val;
+       int *i, vleft, first=1, neg;
        unsigned long lval;
        size_t left, len;

@@ -2251,8 +2251,6 @@ static int __do_proc_dointvec(void *tbl_
                        len = p-buf;
                        if ((len < left) && *p && !isspace(*p))
                                break;
-                       if (neg)
-                               val = -val;
                        s += len;
                        left -= len;
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ