[vlc-commits] var_buffer_getmemory: invalid memcpy source pointer

Alain Degreffe git at videolan.org
Tue Jul 16 14:39:32 CEST 2013


vlc/vlc-2.0 | branch: master | Alain Degreffe <eczema at ecze.com> | Tue Jul 16 08:38:29 2013 +0200| [3ccf9155a069927a4f9ee3c0eff250c5748f1e95] | committer: Jean-Baptiste Kempf

var_buffer_getmemory: invalid memcpy source pointer

Signed-off-by: Rafaël Carré <funman at videolan.org>
(cherry picked from commit 9a74aaad855d14a2e82d8599624280c12dcce5d5)
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc/vlc-2.0.git/?a=commit;h=3ccf9155a069927a4f9ee3c0eff250c5748f1e95
---

 modules/access/mms/buffer.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/access/mms/buffer.c b/modules/access/mms/buffer.c
index b1e8747..c908e27 100644
--- a/modules/access/mms/buffer.c
+++ b/modules/access/mms/buffer.c
@@ -194,7 +194,7 @@ int var_buffer_getmemory ( var_buffer_t *p_buf, void *p_mem, int64_t i_mem )
     i_copy = __MIN( i_mem, p_buf->i_size - p_buf->i_data );
     if( i_copy > 0 && p_mem != NULL)
     {
-        memcpy( p_mem, p_buf + p_buf->i_data, i_copy );
+        memcpy( p_mem, p_buf->p_data + p_buf->i_data , i_copy );
     }
     if( i_copy < 0 )
     {



More information about the vlc-commits mailing list