Signed-off-by: Stephan Holljes <klaxa1...@googlemail.com> --- lavfhttpd.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/lavfhttpd.c b/lavfhttpd.c index 5488e14..d094d65 100644 --- a/lavfhttpd.c +++ b/lavfhttpd.c @@ -66,10 +66,13 @@ int lavfhttpd_accept(void *server, struct HTTPClient **client, int reply_code) int reply_code2 = reply_code; char *method, *resource; if ((ret = avio_accept(server_ctx, &client_ctx)) < 0) { - if (ret == AVERROR(ETIMEDOUT)) + if (ret == AVERROR(ETIMEDOUT)) { return HTTPD_LISTEN_TIMEOUT; - else + } else { + if (client_ctx) + avio_context_free(&client_ctx); return HTTPD_OTHER_ERROR; + } } client_ctx->seekable = 0; ret2 = HTTPD_OK; -- 2.16.2 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel