From 585908a5b6cdd15ea51a8200eff49baa1ed34061 Mon Sep 17 00:00:00 2001 From: Jacek Jendrzej Date: Mon, 1 Nov 2021 21:08:08 +0100 Subject: [PATCH] fix eof with new ffmpeg ABI, see:https://github.com/FFmpeg/FFmpeg/commit/252500a78fe1a31abc79e6070d16f50382c39343 Origin commit data ------------------ Branch: master Commit: https://github.com/neutrino-images/ni-libstb-hal/commit/ec0f9a35317a95f1fd8d87f05dc6f6aceefb3a9a Author: Jacek Jendrzej Date: 2021-11-01 (Mon, 01 Nov 2021) ------------------ No further description and justification available within origin commit message! ------------------ This commit was generated by Migit --- libeplayer3/container/container_ffmpeg.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/libeplayer3/container/container_ffmpeg.c b/libeplayer3/container/container_ffmpeg.c index 40114b5..55d48a4 100644 --- a/libeplayer3/container/container_ffmpeg.c +++ b/libeplayer3/container/container_ffmpeg.c @@ -1396,6 +1396,10 @@ int SAM_ReadFunc(void *ptr, uint8_t *buffer, int lSize) if (!io->pMoovFile) { ret = (int)fread((void *) buffer, (size_t) 1, (size_t) lSize, io->pFile); +#if (LIBAVFORMAT_VERSION_MAJOR > 58) || ((LIBAVFORMAT_VERSION_MAJOR == 79) && (LIBAVFORMAT_VERSION_MINOR > 100)) + if(ret==0) + ret = AVERROR_EOF; +#endif } else {