[MPlayer-cvslog] CVS: main/libmpdemux demux_ty.c,1.16,1.17
Reimar Döffinger CVS
syncmail at mplayerhq.hu
Wed Mar 8 22:13:19 CET 2006
CVS change done by Reimar Döffinger CVS
Update of /cvsroot/mplayer/main/libmpdemux
In directory mail:/var2/tmp/cvs-serv27990
Modified Files:
demux_ty.c
Log Message:
name array is too small, use strlcpy instead of strncpy
Index: demux_ty.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_ty.c,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -r1.16 -r1.17
--- demux_ty.c 17 Feb 2006 01:57:41 -0000 1.16
+++ demux_ty.c 8 Mar 2006 21:13:16 -0000 1.17
@@ -158,7 +158,7 @@
int ty_tmf_filetoparts( demuxer_t *demux, TiVoInfo *tivo )
{
char header[ 512 ];
- char name[ 80 ];
+ char name[ 100 ];
char sizestr[ 80 ];
int size;
int count;
@@ -201,8 +201,8 @@
error = 1;
break;
}
- strncpy( name, &header[ 0 ], 100 );
- strncpy( sizestr, &header[ 124 ], 12 );
+ strlcpy( name, &header[ 0 ], 100 );
+ strlcpy( sizestr, &header[ 124 ], 12 );
size = ty_octaltodecimal( sizestr );
blocks = size / 512;
More information about the MPlayer-cvslog
mailing list