[FFmpeg-devel] [PATCH] Update to latest MPlayer version.

Reimar Döffinger Reimar.Doeffinger at gmx.de
Thu Mar 24 21:26:25 CET 2011


Avoids warnings due to pointlessly casting away const.
---
 libavfilter/libmpcodecs/libvo/fastmemcpy.h |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/libavfilter/libmpcodecs/libvo/fastmemcpy.h b/libavfilter/libmpcodecs/libvo/fastmemcpy.h
index 54980a6..5a17d01 100644
--- a/libavfilter/libmpcodecs/libvo/fastmemcpy.h
+++ b/libavfilter/libmpcodecs/libvo/fastmemcpy.h
@@ -39,7 +39,7 @@ static inline void * mem2agpcpy_pic(void * dst, const void * src, int bytesPerLi
     if(dstStride == srcStride)
     {
         if (srcStride < 0) {
-                src = (uint8_t*)src + (height-1)*srcStride;
+                src = (const uint8_t*)src + (height-1)*srcStride;
                 dst = (uint8_t*)dst + (height-1)*dstStride;
                 srcStride = -srcStride;
         }
@@ -51,7 +51,7 @@ static inline void * mem2agpcpy_pic(void * dst, const void * src, int bytesPerLi
         for(i=0; i<height; i++)
         {
             mem2agpcpy(dst, src, bytesPerLine);
-            src = (uint8_t*)src + srcStride;
+            src = (const uint8_t*)src + srcStride;
             dst = (uint8_t*)dst + dstStride;
         }
     }
@@ -76,7 +76,7 @@ static inline void * memcpy_pic2(void * dst, const void * src,
     if(!limit2width && dstStride == srcStride)
     {
         if (srcStride < 0) {
-                src = (uint8_t*)src + (height-1)*srcStride;
+                src = (const uint8_t*)src + (height-1)*srcStride;
                 dst = (uint8_t*)dst + (height-1)*dstStride;
                 srcStride = -srcStride;
         }
@@ -88,7 +88,7 @@ static inline void * memcpy_pic2(void * dst, const void * src,
         for(i=0; i<height; i++)
         {
             fast_memcpy(dst, src, bytesPerLine);
-            src = (uint8_t*)src + srcStride;
+            src = (const uint8_t*)src + srcStride;
             dst = (uint8_t*)dst + dstStride;
         }
     }
-- 
1.7.4.1




More information about the ffmpeg-devel mailing list