Merge to Fedora kernel-2.6.7-1.441
[linux-2.6.git] / net / core / net-sysfs.c
index 16baf92..20f1616 100644 (file)
@@ -414,7 +414,7 @@ int netdev_register_sysfs(struct net_device *net)
        if ((ret = class_device_register(class_dev)))
                goto out;
 
-       for (i = 0; (attr = net_class_attributes[i]); i++) {
+       for (i = 0; (attr = net_class_attributes[i]) != NULL; i++) {
                if ((ret = class_device_create_file(class_dev, attr)))
                    goto out_unreg;
        }