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

Commit b022a8a3 authored by Ashish Kumar Gupta's avatar Ashish Kumar Gupta Committed by Automerger Merge Worker
Browse files

Update mtp packet buffer am: 960d83c6

parents 9785c4e0 960d83c6
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -168,8 +168,10 @@ void MtpPacket::setParameter(int index, uint32_t value) {
        return;
    }
    int offset = MTP_CONTAINER_PARAMETER_OFFSET + (index - 1) * sizeof(uint32_t);
    if (mPacketSize < offset + sizeof(uint32_t))
    if (mPacketSize < offset + sizeof(uint32_t)) {
        mPacketSize = offset + sizeof(uint32_t);
        allocate(mPacketSize);
    }
    putUInt32(offset, value);
}