[libdvdnav-devel] [PATCH] sprintf -> strcpy

Jean-Baptiste Kempf jb at videolan.org
Wed Sep 9 10:05:52 CEST 2015


On 09 Sep, Lawrence D'Oliveiro wrote :
> On Wed, 9 Sep 2015 09:59:30 +0200, Jean-Baptiste Kempf wrote:
> 
> > On 09 Sep, Lawrence D'Oliveiro wrote :
> >
> >> On Wed,  9 Sep 2015 10:11:16 +0300, Petri Hintukainen wrote:
> >> 
> >>> -    sprintf( filename, "/VIDEO_TS/VIDEO_TS.VOB" );
> >>> +    strcpy( filename, "/VIDEO_TS/VIDEO_TS.VOB" );
> >> [etc]
> >> 
> >> I would not use either. I would use strncpy instead.
> > 
> > strlcpy, maybe?
> 
> Sounds good, but it’s not POSIX, is it?

So what?

With my kindest regards,

-- 
Jean-Baptiste Kempf
http://www.jbkempf.com/ - +33 672 704 734
Sent from my Electronic Device


More information about the libdvdnav-devel mailing list