2
0
mirror of https://github.com/openvswitch/ovs synced 2025-08-30 22:05:19 +00:00

dpif-linux: Fix file descriptor leak.

get_major() opens /proc/devices to get the openvswitch major number
but never closes the FD.
This commit is contained in:
Tetsuo NAKAGAWA
2010-03-25 10:54:15 -04:00
committed by Jesse Gross
parent 4c77ea7fe0
commit ed30fb10e1

View File

@@ -677,6 +677,8 @@ get_major(const char *target)
}
}
fclose(file);
VLOG_ERR("%s: %s major not found (is the module loaded?)", fn, target);
return -ENODEV;
}