usb: pd: Avoid buffer overrun during msg_rx
When copying the buffer to the rx_msg structure, ensure
that we do not copy more than the payload buffer size.
Guard the unknown len parameter within a min() check.
Change-Id: I55feff0dbee59b680a42878a38da8e9742332008
Signed-off-by:
Jack Pham <jackp@codeaurora.org>
Loading
Please register or sign in to comment