[vlc-commits] var_buffer_getmemory: invalid memcpy source pointer

Alain Degreffe git at videolan.org
Tue Jul 16 14:34:59 CEST 2013


vlc/vlc-2.1 | branch: master | Alain Degreffe <eczema at ecze.com> | Tue Jul 16 08:38:29 2013 +0200| [c62dbabf14cf07fba19474a6f23ce9bbac96aa16] | 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.1.git/?a=commit;h=c62dbabf14cf07fba19474a6f23ce9bbac96aa16
---

 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 4600662..4e11e36 100644
--- a/modules/access/mms/buffer.c
+++ b/modules/access/mms/buffer.c
@@ -198,7 +198,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