Mercurial > libavcodec.hg
diff audioconvert.c @ 8784:7c47da8e2cf8 libavcodec
Replace snprintf() with av_strlcpy().
Fixes the following warning on some systems:
audioconvert.c:131: warning: format not a string literal and no format
arguments
Patch by Patrik patrik A yes D nu
author | cehoyos |
---|---|
date | Mon, 09 Feb 2009 23:11:26 +0000 |
parents | e9d9d946f213 |
children | f7bd7e90ef9f |
line wrap: on
line diff
--- a/audioconvert.c Mon Feb 09 23:04:16 2009 +0000 +++ b/audioconvert.c Mon Feb 09 23:11:26 2009 +0000 @@ -128,7 +128,7 @@ for (i=0; channel_layout_map[i].name; i++) if (nb_channels == channel_layout_map[i].nb_channels && channel_layout == channel_layout_map[i].layout) { - snprintf(buf, buf_size, channel_layout_map[i].name); + av_strlcpy(buf, channel_layout_map[i].name, buf_size); return; }