mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] [2.6.22] Remove unneeded pointer idev from addrconf_cleanup() in net/ipv6/addrconf.c
@ 2007-07-09  3:30 Micah Gruber
  2007-07-11  6:05 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Micah Gruber @ 2007-07-09  3:30 UTC (permalink / raw)
  To: linux-kernel, netdev, pekkas

This trivial patch removes the unneeded pointer idev returned from
__in6_dev_get(), which is never used. The check for NULL can be simply
done by if (__in6_dev_get(dev) == NULL).

Signed-off-by: Micah Gruber < micah.gruber@gmail.com>

--- a/net/ipv6/addrconf.c
+++ b/net/ipv6/addrconf.c
@@ -4240,7 +4240,6 @@
void __exit addrconf_cleanup(void)
{
        struct net_device *dev;
-       struct inet6_dev *idev;
        struct inet6_ifaddr *ifa;
        int i;

@@ -4258,7 +4257,7 @@
         */

        for_each_netdev(dev) {
-               if ((idev = __in6_dev_get(dev)) == NULL)
+               if (__in6_dev_get(dev) == NULL)
                        continue;
                addrconf_ifdown(dev, 1);
        }

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] [2.6.22] Remove unneeded pointer idev from addrconf_cleanup() in net/ipv6/addrconf.c
  2007-07-09  3:30 [PATCH] [2.6.22] Remove unneeded pointer idev from addrconf_cleanup() in net/ipv6/addrconf.c Micah Gruber
@ 2007-07-11  6:05 ` David Miller
  0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2007-07-11  6:05 UTC (permalink / raw)
  To: micah.gruber; +Cc: linux-kernel, netdev, pekkas

From: "Micah Gruber" <micah.gruber@gmail.com>
Date: Mon, 9 Jul 2007 11:30:46 +0800

> This trivial patch removes the unneeded pointer idev returned from
> __in6_dev_get(), which is never used. The check for NULL can be simply
> done by if (__in6_dev_get(dev) == NULL).
> 
> Signed-off-by: Micah Gruber < micah.gruber@gmail.com>

Applied, but your patch was severely white-space damaged by your
email client, please fix this up and test that the patches you
email out can be applied by those receiving the posting in the
future.

Thanks.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2007-07-11  6:34 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-07-09  3:30 [PATCH] [2.6.22] Remove unneeded pointer idev from addrconf_cleanup() in net/ipv6/addrconf.c Micah Gruber
2007-07-11  6:05 ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®