[vlc-devel] [PATCH] se/archive: fix seeking with SEEK_END

Pierre Lamot pierre at videolabs.io
Fri Dec 1 17:21:43 CET 2017


  fix: #19133
---
 modules/stream_extractor/archive.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/stream_extractor/archive.c b/modules/stream_extractor/archive.c
index 9796d0b7bd..4fdb3b1378 100644
--- a/modules/stream_extractor/archive.c
+++ b/modules/stream_extractor/archive.c
@@ -167,7 +167,7 @@ static la_int64_t libarchive_seek_cb( libarchive_t* p_arc, void* p_obj,
     {
         case SEEK_SET: whence_pos = 0;                           break;
         case SEEK_CUR: whence_pos = vlc_stream_Tell( p_source ); break;
-        case SEEK_END: whence_pos = stream_Size( p_source ) - 1; break;
+        case SEEK_END: whence_pos = stream_Size( p_source ); break;
               default: vlc_assert_unreachable();
 
     }
-- 
2.14.1



More information about the vlc-devel mailing list