avctp: Fix not accounting output MTU properly
authorLuiz Augusto von Dentz <luiz.von.dentz@intel.com>
Wed, 3 Jul 2019 12:25:00 +0000 (15:25 +0300)
committerhimanshu <h.himanshu@samsung.com>
Tue, 11 Feb 2020 08:57:47 +0000 (14:27 +0530)
The code shall use BT_IO_OPT_OMTU to read the output MTU.

Change-Id: Ie97e172469b26177a612c8f2d3231c196e877a83
Signed-off-by: himanshu <h.himanshu@samsung.com>
profiles/audio/avctp.c

index 0c4bb82..44eb19c 100644 (file)
@@ -1428,7 +1428,7 @@ static void avctp_connect_cb(GIOChannel *chan, GError *err, gpointer data)
        bt_io_get(chan, &gerr,
                        BT_IO_OPT_DEST, &address,
                        BT_IO_OPT_IMTU, &imtu,
-                       BT_IO_OPT_IMTU, &omtu,
+                       BT_IO_OPT_OMTU, &omtu,
                        BT_IO_OPT_INVALID);
        if (gerr) {
                avctp_set_state(session, AVCTP_STATE_DISCONNECTED, -EIO);