mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-19 22:10:34 +00:00
7l trocadero: reading right into enum variable may cause unwanted effects, use
intermediate buffer for reading value instead in RTMP protocol handler. Originally committed as revision 20682 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
00b6fa40c3
commit
1ab21f1980
@ -102,8 +102,9 @@ int ff_rtmp_packet_read(URLContext *h, RTMPPacket *p,
|
||||
if (url_read_complete(h, buf, 3) != 3)
|
||||
return AVERROR(EIO);
|
||||
data_size = AV_RB24(buf);
|
||||
if (url_read_complete(h, &type, 1) != 1)
|
||||
if (url_read_complete(h, buf, 1) != 1)
|
||||
return AVERROR(EIO);
|
||||
type = buf[0];
|
||||
if (hdr == RTMP_PS_TWELVEBYTES) {
|
||||
if (url_read_complete(h, buf, 4) != 4)
|
||||
return AVERROR(EIO);
|
||||
|
Loading…
Reference in New Issue
Block a user