[PATCH BlueZ 1/1] btio: Fix BASE copy from getsockopt()

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

 



Fix copy of BASE from getsockopt() and update base length.

---
 btio/btio.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/btio/btio.c b/btio/btio.c
index 8178250d2..8d9959038 100644
--- a/btio/btio.c
+++ b/btio/btio.c
@@ -1649,10 +1649,12 @@ static gboolean iso_get(int sock, GError **err, BtIOOption opt1, va_list args)
 		return FALSE;
 	}
 
-	if (getsockopt(sock, SOL_BLUETOOTH, BT_ISO_BASE, &base, &len) < 0) {
+	if (getsockopt(sock, SOL_BLUETOOTH, BT_ISO_BASE,
+			&base.base, &len) < 0) {
 		ERROR_FAILED(err, "getsockopt(BT_ISO_BASE)", errno);
 		return FALSE;
 	}
+	base.base_len = len;
 
 	if (!get_src(sock, &src, sizeof(src), err))
 		return FALSE;
-- 
2.34.1




[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