Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2022-05-23 02:23:22 +0300
committerMichael Niedermayer <michael@niedermayer.cc>2022-10-28 22:04:04 +0300
commit07350dede59178feb5e862bbbbe85567362d1408 (patch)
tree0c122e24d71a29b6cbf9e61e869ffbf09dfa710d
parentbafac17227a5757af3d9ead9ac9bef5330254a31 (diff)
avformat/sctp: close socket on errors
This is untested as i have no testcase Fixes: CID1302709 Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit c9a2996544187f67e533bc24f4cf773e50d2362b) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r--libavformat/sctp.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavformat/sctp.c b/libavformat/sctp.c
index 1d8261576c..058dfbf1fc 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;