git.droids-corp.org
/
dpdk.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
db803c3
)
bus/vmbus: close directory in error path
author
Stephen Hemminger
<sthemmin@microsoft.com>
Mon, 6 Aug 2018 18:11:06 +0000
(11:11 -0700)
committer
Thomas Monjalon
<thomas@monjalon.net>
Tue, 7 Aug 2018 12:41:40 +0000
(14:41 +0200)
Fix bug reported by Coverity where directory being scanned was
not closed in error path (leaking file descriptor).
Coverity issue: 302848
Fixes:
831dba47bd36
("bus/vmbus: add Hyper-V virtual bus support")
Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com>
drivers/bus/vmbus/linux/vmbus_uio.c
patch
|
blob
|
history
diff --git
a/drivers/bus/vmbus/linux/vmbus_uio.c
b/drivers/bus/vmbus/linux/vmbus_uio.c
index
b0f8eba
..
0b1b153
100644
(file)
--- a/
drivers/bus/vmbus/linux/vmbus_uio.c
+++ b/
drivers/bus/vmbus/linux/vmbus_uio.c
@@
-357,6
+357,7
@@
int vmbus_uio_get_subchan(struct vmbus_channel *primary,
if (err) {
VMBUS_LOG(NOTICE, "invalid subchannel id %lu",
subid);
+ closedir(chan_dir);
return err;
}