Skip to content

Commit

Permalink
nimble/audio/bass: Control point buffer fix
Browse files Browse the repository at this point in the history
Remove unnecessary buffer from operation.
Pass proper buffer to handler.
  • Loading branch information
szymon-czapracki committed Oct 31, 2024
1 parent 8f6b9df commit 06dc8f9
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions nimble/host/audio/services/bass/src/ble_audio_svc_bass.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;

Expand All @@ -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
Expand Down

0 comments on commit 06dc8f9

Please sign in to comment.