Toggle navigation
EN
EN
DE
ES
FR
IT
UK
Help
Log In
Help
Log In
EN
EN
DE
ES
FR
IT
UK
Home
Messages
Hashtags
Subgroups
×
×
×
Close
Likes
Cip-Dev
Messages
×
Close
Search
Single
Toggle Dropdown
Messages
Topics
Expanded
Polls
previous page
#5570
next page
[RFC PATCH 4.19.y-cip 50/50] tools: PCI: Fix fd leakage
Lad Prabhakar
#5570
From: Hewenliang <hewenliang4@...>
commit 3c379a59b4795d7279d38c623e74b9790345a32b upstream.
We should close fd before the return of run_test.
Fixes: 3f2ed8134834 ("tools: PCI: Add a userspace tool to test PCI endpoint")
Signed-off-by: Hewenliang <hewenliang4@...>
Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@...>
Acked-by: Kishon Vijay Abraham I <kishon@...>
Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@...>
---
tools/pci/pcitest.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/tools/pci/pcitest.c b/tools/pci/pcitest.c
index b7e3b6a64956..9f3d2e584ce4 100644
--- a/tools/pci/pcitest.c
+++ b/tools/pci/pcitest.c
@@ -140,6 +140,7 @@ static int run_test(struct pci_test *test)
}
fflush(stdout);
+ close(fd);
return (ret < 0) ? ret : 1 - ret; /* return 0 if test succeeded */
}
--
2.17.1
More
All Messages By This Member
×
previous page
#5570
next page
Join
cip-dev@lists.cip-project.org to automatically receive all group messages.
×
Close
Report Message
Reason
Report to Moderators
I think this message isn't appropriate for our group. The Group moderators are responsible for maintaining their community and can address these issues.
Report to CIP Project Support
I think this violates the Terms of Service. This includes: harm to minors, violence or threats, harassment or privacy invasion, impersonation or misrepresentation, fraud or phishing.
Note:
Your email address is included with the abuse report.
×
Close
Verify Delete
Are you sure you wish to delete this message from the message archives of cip-dev@lists.cip-project.org?
This cannot be undone.
×
Close
Verify Repost
Are you sure you wish to repost this message?
More Options
More
Home
Hashtags
Subgroups
Terms
Toggle navigation
Terms
©
2023
Groups.io