rtp: Fixed size check in padded RTP packets
This patch fixes a corner case (padding 1, payload size incl padding 0) which is not being detected correctly. Sponsored-by: On-Waves ehf
This commit is contained in:
parent
33b9641025
commit
d9e4039516
|
@ -151,7 +151,7 @@ static int rtp_decode(struct msgb *msg, uint32_t callref, struct msgb **data)
|
|||
}
|
||||
}
|
||||
if (rtph->padding) {
|
||||
if (payload_len < 0) {
|
||||
if (payload_len < 1) {
|
||||
DEBUGPC(DLMUX, "received RTP frame too short for "
|
||||
"padding length\n");
|
||||
return -EINVAL;
|
||||
|
|
Loading…
Reference in New Issue