diff options
author | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2009-05-14 18:54:25 +0000 |
---|---|---|
committer | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2009-05-14 18:54:25 +0000 |
commit | b69b622c22879b807220576100d0cf7b058e072f (patch) | |
tree | e1cf5d5a239b946fa652467a5b54fe3994263207 /libavfilter/parseutils.c | |
parent | be1fb76fa11b0897d326782ddfb06624105a64bf (diff) | |
download | ffmpeg-b69b622c22879b807220576100d0cf7b058e072f.tar.gz |
Make case insensitive the match for the color name in
av_parse_color().
Originally committed as revision 18827 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavfilter/parseutils.c')
-rw-r--r-- | libavfilter/parseutils.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libavfilter/parseutils.c b/libavfilter/parseutils.c index 9ee1ae6db2..13fa58199e 100644 --- a/libavfilter/parseutils.c +++ b/libavfilter/parseutils.c @@ -22,7 +22,7 @@ * parsing utils */ -#include <string.h> +#include <strings.h> #include "libavutil/avutil.h" #include "libavutil/random_seed.h" #include "parseutils.h" @@ -212,12 +212,12 @@ static ColorEntry color_table[] = { static int color_table_compare(const void *lhs, const void *rhs) { - return strcmp(lhs, ((const ColorEntry *)rhs)->name); + return strcasecmp(lhs, ((const ColorEntry *)rhs)->name); } int av_parse_color(uint8_t *rgba_color, const char *color_string, void *log_ctx) { - if (!strcmp(color_string, "bikeshed")) { + if (!strcasecmp(color_string, "bikeshed")) { int rgba = ff_random_get_seed(); rgba_color[0] = rgba >> 24; rgba_color[1] = rgba >> 16; |