From 75e61b0e88ddb17fa57f8e3bc10d27cb1282a815 Mon Sep 17 00:00:00 2001 From: Måns Rullgård Date: Sat, 23 Jun 2007 23:10:32 +0000 Subject: use new string functions based on patch by Reimar Döffinger MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Originally committed as revision 9401 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavformat/mp3.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'libavformat/mp3.c') diff --git a/libavformat/mp3.c b/libavformat/mp3.c index c0d7f8a11c..4a03c00fa4 100644 --- a/libavformat/mp3.c +++ b/libavformat/mp3.c @@ -20,6 +20,7 @@ */ #include "avformat.h" #include "mpegaudio.h" +#include "avstring.h" #define ID3v2_HEADER_SIZE 10 #define ID3v1_TAG_SIZE 128 @@ -350,7 +351,7 @@ static int id3v1_parse_tag(AVFormatContext *s, const uint8_t *buf) s->track = buf[126]; genre = buf[127]; if (genre <= ID3v1_GENRE_MAX) - pstrcpy(s->genre, sizeof(s->genre), id3v1_genre_str[genre]); + av_strlcpy(s->genre, id3v1_genre_str[genre], sizeof(s->genre)); return 0; } -- cgit v1.2.3