From bb3244dee26e3c500b14830e9500cb2d3658f809 Mon Sep 17 00:00:00 2001 From: Reimar Döffinger Date: Wed, 2 Nov 2011 20:17:25 +0100 Subject: Replace all usage of strcasecmp/strncasecmp MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit All current usages of it are incompatible with localization. For example strcasecmp("i", "I") != 0 is possible, but would break many of the places where it is used. Instead use our own implementations that always treat the data as ASCII. Signed-off-by: Martin Storsjö --- libavformat/metadata.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'libavformat/metadata.c') diff --git a/libavformat/metadata.c b/libavformat/metadata.c index d8957dfa95..7d85363cfe 100644 --- a/libavformat/metadata.c +++ b/libavformat/metadata.c @@ -18,10 +18,10 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ -#include #include "avformat.h" #include "metadata.h" #include "libavutil/dict.h" +#include "libavutil/avstring.h" #if FF_API_OLD_METADATA2 AVDictionaryEntry * @@ -69,13 +69,13 @@ void ff_metadata_conv(AVDictionary **pm, const AVMetadataConv *d_conv, key = mtag->key; if (s_conv) for (sc=s_conv; sc->native; sc++) - if (!strcasecmp(key, sc->native)) { + if (!av_strcasecmp(key, sc->native)) { key = sc->generic; break; } if (d_conv) for (dc=d_conv; dc->native; dc++) - if (!strcasecmp(key, dc->generic)) { + if (!av_strcasecmp(key, dc->generic)) { key = dc->native; break; } -- cgit v1.2.3