]> git.sesse.net Git - vlc/commitdiff
avformat: add support to IOSeek() for AVSEEK_SIZE (retrieving size without seeking)
authorDerk-Jan Hartman <hartman@videolan.org>
Tue, 29 Jul 2008 22:06:05 +0000 (00:06 +0200)
committerDerk-Jan Hartman <hartman@videolan.org>
Wed, 30 Jul 2008 01:33:48 +0000 (03:33 +0200)
modules/demux/avformat/demux.c

index e3254b2d8d7d5e37c80ff52bb30e6c13384436b4..72ccd75808f9eec4172ac5e0e47e6033be689107 100644 (file)
@@ -496,6 +496,10 @@ static offset_t IOSeek( void *opaque, offset_t offset, int whence )
 
     switch( whence )
     {
+#ifdef AVSEEK_SIZE
+        case AVSEEK_SIZE:
+            return i_size;
+#endif
         case SEEK_SET:
             break;
         case SEEK_CUR: