ffmpeg | branch: release/3.4 | Michael Niedermayer <mich...@niedermayer.cc> | 
Mon May 23 01:23:22 2022 +0200| [6d40df7ea76680071ef7ed96731a21a0f0f83407] | 
committer: Michael Niedermayer

avformat/sctp: close socket on errors

This is untested as i have no testcase

Fixes: CID1302709

Signed-off-by: Michael Niedermayer <mich...@niedermayer.cc>
(cherry picked from commit c9a2996544187f67e533bc24f4cf773e50d2362b)
Signed-off-by: Michael Niedermayer <mich...@niedermayer.cc>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=6d40df7ea76680071ef7ed96731a21a0f0f83407
---

 libavformat/sctp.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavformat/sctp.c b/libavformat/sctp.c
index 9a80e9b015..be0cb47865 100644
--- a/libavformat/sctp.c
+++ b/libavformat/sctp.c
@@ -282,6 +282,8 @@ fail:
         goto restart;
     }
 fail1:
+    if (fd >= 0)
+        closesocket(fd);
     ret = AVERROR(EIO);
     freeaddrinfo(ai);
     return ret;

_______________________________________________
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

To unsubscribe, visit link above, or email
ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".

Reply via email to