This is an automated email from the ASF dual-hosted git repository.

janc pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-nimble.git


The following commit(s) were added to refs/heads/master by this push:
     new 1d65368c7 nimble/audio/bass: Control point buffer fix
1d65368c7 is described below

commit 1d65368c7a05a958378e9a71026f05abbd3115b7
Author: Szymon Czapracki <[email protected]>
AuthorDate: Thu Oct 31 14:53:43 2024 +0100

    nimble/audio/bass: Control point buffer fix
    
    Remove unnecessary buffer from operation.
    Pass proper buffer to handler.
---
 nimble/host/audio/services/bass/src/ble_audio_svc_bass.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/nimble/host/audio/services/bass/src/ble_audio_svc_bass.c 
b/nimble/host/audio/services/bass/src/ble_audio_svc_bass.c
index e3cecb060..bc04631b9 100644
--- a/nimble/host/audio/services/bass/src/ble_audio_svc_bass.c
+++ b/nimble/host/audio/services/bass/src/ble_audio_svc_bass.c
@@ -669,7 +669,6 @@ static int
 ble_svc_audio_bass_ctrl_point_write_access(struct ble_gatt_access_ctxt *ctxt, 
uint16_t conn_handle)
 {
     uint8_t opcode;
-    struct os_mbuf *om;
     uint16_t mbuf_len = OS_MBUF_PKTLEN(ctxt->om);
     struct ble_svc_audio_bass_ctrl_point_handler *handler;
 
@@ -692,7 +691,7 @@ ble_svc_audio_bass_ctrl_point_write_access(struct 
ble_gatt_access_ctxt *ctxt, ui
         return BLE_ATT_ERR_UNLIKELY;
     }
 
-    return handler->handler_cb(&om->om_data[1], mbuf_len - 1, conn_handle);
+    return handler->handler_cb(&ctxt->om->om_data[1], mbuf_len - 1, 
conn_handle);
 }
 
 static int

Reply via email to