]> err.no Git - systemd/commitdiff
fix major fd leak in link handling
authorMartin Pitt <martin.pitt@ubuntu.com>
Mon, 2 Nov 2009 23:03:43 +0000 (00:03 +0100)
committerMartin Pitt <martin.pitt@ubuntu.com>
Mon, 2 Nov 2009 23:03:43 +0000 (00:03 +0100)
link_find_prioritized(): Properly close directory handles to fix a major fd
leak which caused hotplugging to fail entirely in many cases due to having too
many open files.

https://launchpad.net/bugs/463347

udev/udev-node.c

index 8c2154d37e4b6d35d0c00eac6764d8d363691ab2..24f2ccf618cd14592c3762640b76fd168521e4df 100644 (file)
@@ -281,6 +281,7 @@ static const char *link_find_prioritized(struct udev_device *dev, bool add, cons
                        udev_device_unref(dev_db);
                }
        }
+       closedir(dir);
        return target;
 }