[FFmpeg-devel] [PATCH] lavf/libsmbclient: return AVERROR_EOF for EOF.

Nicolas George george at nsup.org
Thu Aug 30 15:43:27 EEST 2018


Fix trac ticket #7387.

Signed-off-by: Nicolas George <george at nsup.org>
---
 libavformat/libsmbclient.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


Untested, I do not have a SMB share at hand.


diff --git a/libavformat/libsmbclient.c b/libavformat/libsmbclient.c
index b68cd8bd79..3285868957 100644
--- a/libavformat/libsmbclient.c
+++ b/libavformat/libsmbclient.c
@@ -166,7 +166,7 @@ static int libsmbc_read(URLContext *h, unsigned char *buf, int size)
         return ret;
     }
 
-    return bytes_read;
+    return bytes_read ? bytes_read : AVERROR_EOF;
 }
 
 static int libsmbc_write(URLContext *h, const unsigned char *buf, int size)
-- 
2.18.0



More information about the ffmpeg-devel mailing list