Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4c994a05 authored by Sungsoo Lim's avatar Sungsoo Lim Committed by Gerrit Code Review
Browse files

Merge "Fix memory leak in BNEP_WriteBuf" into main

parents aff4bfe1 305c4cc9
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -388,7 +388,10 @@ tBNEP_RESULT BNEP_WriteBuf(uint16_t handle, const RawAddress& p_dest_addr,
        protocol = 0;
      else {
        new_len += 4;
        if (new_len > org_len) return BNEP_IGNORE_CMD;
        if (new_len > org_len) {
          osi_free(p_buf);
          return BNEP_IGNORE_CMD;
        }
        p_data[2] = 0;
        p_data[3] = 0;
      }