[FFmpeg-devel] [PATCH] avformat/http: add string of the error when only return error number

Steven Liu lq at chinaffmpeg.org
Mon Jul 1 10:27:00 EEST 2019


Signed-off-by: Steven Liu <lq at chinaffmpeg.org>
---
 libavformat/http.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/http.c b/libavformat/http.c
index 5a937994cf..1ee4d5189c 100644
--- a/libavformat/http.c
+++ b/libavformat/http.c
@@ -1638,7 +1638,7 @@ static int http_shutdown(URLContext *h, int flags)
             read_ret = ffurl_read(s->hd, buf, sizeof(buf));
             s->hd->flags &= ~AVIO_FLAG_NONBLOCK;
             if (read_ret < 0 && read_ret != AVERROR(EAGAIN)) {
-                av_log(h, AV_LOG_ERROR, "URL read error:  %d\n", read_ret);
+                av_log(h, AV_LOG_ERROR, "URL read error:  %d(%s)\n", read_ret, av_err2str(read_ret));
                 ret = read_ret;
             }
         }
-- 
2.17.2 (Apple Git-113)





More information about the ffmpeg-devel mailing list