[MPlayer-cvslog] r35360 - in trunk: libmpdemux/demux_lavf.c libmpdemux/muxer_lavf.c stream/cache2.c stream/stream_ffmpeg.c stream/stream_file.c stream/stream_smb.c

reimar subversion at mplayerhq.hu
Tue Nov 6 18:31:23 CET 2012


Author: reimar
Date: Tue Nov  6 18:31:23 2012
New Revision: 35360

Log:
Change STREAM_CTRL_GET_SIZE argument type from off_t to
uint64_t.
Also fix the incorrect type of the uint64_res variable.

Modified:
   trunk/libmpdemux/demux_lavf.c
   trunk/libmpdemux/muxer_lavf.c
   trunk/stream/cache2.c
   trunk/stream/stream_ffmpeg.c
   trunk/stream/stream_file.c
   trunk/stream/stream_smb.c

Modified: trunk/libmpdemux/demux_lavf.c
==============================================================================
--- trunk/libmpdemux/demux_lavf.c	Tue Nov  6 16:53:41 2012	(r35359)
+++ trunk/libmpdemux/demux_lavf.c	Tue Nov  6 18:31:23 2012	(r35360)
@@ -106,7 +106,7 @@ static int64_t mp_seek(void *opaque, int
     else if(whence == SEEK_SET)
         pos += stream->start_pos;
     else if(whence == AVSEEK_SIZE && stream->end_pos > 0) {
-        off_t size;
+        uint64_t size;
         stream_control(stream, STREAM_CTRL_GET_SIZE, &size);
         if (size > stream->end_pos)
             stream->end_pos = size;

Modified: trunk/libmpdemux/muxer_lavf.c
==============================================================================
--- trunk/libmpdemux/muxer_lavf.c	Tue Nov  6 16:53:41 2012	(r35359)
+++ trunk/libmpdemux/muxer_lavf.c	Tue Nov  6 18:31:23 2012	(r35360)
@@ -96,7 +96,7 @@ static int64_t mp_seek(void *opaque, int
 	}
 	else if(whence == SEEK_END)
 	{
-		off_t size=0;
+		uint64_t size=0;
 		if(stream_control(muxer->stream, STREAM_CTRL_GET_SIZE, &size) == STREAM_UNSUPPORTED || size < pos)
 			return -1;
 		pos = size - pos;

Modified: trunk/stream/cache2.c
==============================================================================
--- trunk/stream/cache2.c	Tue Nov  6 16:53:41 2012	(r35359)
+++ trunk/stream/cache2.c	Tue Nov  6 18:31:23 2012	(r35360)
@@ -264,7 +264,7 @@ static int cache_fill(cache_vars_t *s)
 static int cache_execute_control(cache_vars_t *s) {
   double double_res;
   unsigned uint_res;
-  unsigned uint64_res;
+  uint64_t uint64_res;
   int needs_flush = 0;
   static unsigned last;
   int quit = s->control == -2;
@@ -693,7 +693,7 @@ int cache_do_control(stream_t *stream, i
       *(unsigned *)arg = s->control_uint_arg;
       break;
     case STREAM_CTRL_GET_SIZE:
-      *(off_t *)arg = s->control_uint_arg;
+      *(uint64_t *)arg = s->control_uint_arg;
       break;
     case STREAM_CTRL_GET_LANG:
       *(struct stream_lang_req *)arg = s->control_lang_arg;

Modified: trunk/stream/stream_ffmpeg.c
==============================================================================
--- trunk/stream/stream_ffmpeg.c	Tue Nov  6 16:53:41 2012	(r35359)
+++ trunk/stream/stream_ffmpeg.c	Tue Nov  6 18:31:23 2012	(r35360)
@@ -61,7 +61,7 @@ static int control(stream_t *s, int cmd,
     case STREAM_CTRL_GET_SIZE:
         size = avio_size(s->priv);
         if(size >= 0) {
-            *(off_t *)arg = size;
+            *(uint64_t *)arg = size;
             return 1;
         }
         break;

Modified: trunk/stream/stream_file.c
==============================================================================
--- trunk/stream/stream_file.c	Tue Nov  6 16:53:41 2012	(r35359)
+++ trunk/stream/stream_file.c	Tue Nov  6 18:31:23 2012	(r35360)
@@ -106,7 +106,7 @@ static int control(stream_t *s, int cmd,
       size = lseek(s->fd, 0, SEEK_END);
       lseek(s->fd, s->pos, SEEK_SET);
       if(size != (off_t)-1) {
-        *((off_t*)arg) = size;
+        *(uint64_t*)arg = size;
         return 1;
       }
     }

Modified: trunk/stream/stream_smb.c
==============================================================================
--- trunk/stream/stream_smb.c	Tue Nov  6 16:53:41 2012	(r35359)
+++ trunk/stream/stream_smb.c	Tue Nov  6 18:31:23 2012	(r35360)
@@ -78,7 +78,7 @@ static int control(stream_t *s, int cmd,
       off_t size = smbc_lseek(s->fd,0,SEEK_END);
       smbc_lseek(s->fd,s->pos,SEEK_SET);
       if(size != (off_t)-1) {
-        *((off_t*)arg) = size;
+        *(uint64_t *)arg = size;
         return 1;
       }
     }


More information about the MPlayer-cvslog mailing list