[dpdk-dev,v2] Restore support for virtio on FreeBSD

Message ID 1428450513-98003-1-git-send-email-razamir22@gmail.com (mailing list archive)
State Superseded, archived
Headers

Commit Message

Raz Amir April 7, 2015, 11:48 p.m. UTC
Fixes: 8a312224bcde ("eal/bsd: fix fd leak")

Signed-off-by: Raz Amir <razamir22@gmail.com>
---
 lib/librte_eal/bsdapp/eal/eal.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Patch

diff --git a/lib/librte_eal/bsdapp/eal/eal.c b/lib/librte_eal/bsdapp/eal/eal.c
index 871d5f4..e20f915 100644
--- a/lib/librte_eal/bsdapp/eal/eal.c
+++ b/lib/librte_eal/bsdapp/eal/eal.c
@@ -426,7 +426,7 @@  rte_eal_iopl_init(void)
 	fd = open("/dev/io", O_RDWR);
 	if (fd < 0)
 		return -1;
-	close(fd);
+	/* keep fd open for iopl */
 	return 0;
 }