[PATCH 3/3] btproxy: Fix closing invalid file descriptor

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Andrei Emeltchenko <andrei.emeltchenko@xxxxxxxxx>

Instead of invalid file descriptor dst_fd close src_fd.
---
 tools/btproxy.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/btproxy.c b/tools/btproxy.c
index 3c7c48f..1573587 100644
--- a/tools/btproxy.c
+++ b/tools/btproxy.c
@@ -659,7 +659,7 @@ int main(int argc, char *argv[])
 
 		dst_fd = open_vhci(0x00);
 		if (dst_fd < 0) {
-			close(dst_fd);
+			close(src_fd);
 			return EXIT_FAILURE;
 		}
 
-- 
1.8.3.2

--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux