• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
Keine Tags

Frequently used words (click to add to your profile)

javaandroidc++linuxc#objective-ccocoa誰得qtrubybathyscaphegamephpguicwindows翻訳pythonomegattwitterframeworkbtronarduinovb.net計画中(planning stage)directxpreviewertestゲームエンジンdom

system/bt


Commit MetaInfo

Revisionb882eee2da11673ff71193948d6b789d441d430d (tree)
Zeit2017-10-07 05:11:29
AutorDan Pasanen <dan.pasanen@gmai...>
CommiterDan Pasanen

Log Message

Fix allocating buffers of the right size when BT_HDR is included

Missed in 8825957cc44b705c782c8b2d33c87a66e02376f6

Change-Id: I5d631f609578ef8e4e2626d7f4a1cc77a6d90ecf

Ändern Zusammenfassung

Diff

--- a/stack/mcap/mca_cact.c
+++ b/stack/mcap/mca_cact.c
@@ -410,7 +410,7 @@ void mca_ccb_hdl_req(tMCA_CCB *p_ccb, tMCA_CCB_EVT *p_data)
410410
411411 if (((reject_code != MCA_RSP_SUCCESS) && (evt_data.hdr.op_code != MCA_OP_SYNC_INFO_IND))
412412 || send_rsp) {
413- BT_HDR *p_buf = (BT_HDR *)osi_malloc(MCA_CTRL_MTU);
413+ BT_HDR *p_buf = (BT_HDR *)osi_malloc(MCA_CTRL_MTU + sizeof(BT_HDR));
414414 p_buf->offset = L2CAP_MIN_OFFSET;
415415 p = p_start = (UINT8*)(p_buf + 1) + L2CAP_MIN_OFFSET;
416416 *p++ = reject_opcode;