[FFmpeg-devel] [PATCH 2/2] http: pass return code from http_open_cnx_internal() on its failure
Andrey Utkin
andrey.utkin at corp.bluecherry.net
Thu Oct 23 18:55:46 CEST 2014
Previously, AVERROR(EIO) was returned on failure of
http_open_cnx_internal(). Now the value is passed to upper level, thus
it is possible to distinguish ECONNREFUSED, ETIMEDOUT, ENETUNREACH etc.
---
libavformat/http.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/libavformat/http.c b/libavformat/http.c
index d12dcaa..dfc01ee 100644
--- a/libavformat/http.c
+++ b/libavformat/http.c
@@ -250,6 +250,8 @@ redo:
fail:
if (s->hd)
ffurl_closep(&s->hd);
+ if (location_changed < 0)
+ return location_changed;
return ff_http_averror(s->http_code, AVERROR(EIO));
}
--
1.8.5.5
More information about the ffmpeg-devel
mailing list