diff options
author | Limin Wang <lance.lmwang@gmail.com> | 2020-11-04 20:44:43 +0800 |
---|---|---|
committer | Limin Wang <lance.lmwang@gmail.com> | 2020-11-11 18:32:56 +0800 |
commit | aa1fab6934baf3528a5a344511e6bb3a19f6ff6f (patch) | |
tree | 5cdb7ff4960a2d101b30292b750963bbe1790e5e /libavformat/rtsp.c | |
parent | 001ccbc5ccf0791e2aa9d583b9b527adc9a62e82 (diff) | |
download | ffmpeg-aa1fab6934baf3528a5a344511e6bb3a19f6ff6f.tar.gz |
avformat/rtsp: check return value of ffurl_read_complete
Signed-off-by: Limin Wang <lance.lmwang@gmail.com>
Diffstat (limited to 'libavformat/rtsp.c')
-rw-r--r-- | libavformat/rtsp.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c index 9c693f1115..5ef2f23dc2 100644 --- a/libavformat/rtsp.c +++ b/libavformat/rtsp.c @@ -1220,7 +1220,8 @@ start: content = av_malloc(content_length + 1); if (!content) return AVERROR(ENOMEM); - ffurl_read_complete(rt->rtsp_hd, content, content_length); + if (ffurl_read_complete(rt->rtsp_hd, content, content_length) != content_length) + return AVERROR(EIO); content[content_length] = '\0'; } if (content_ptr) |