diff options
author | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2010-05-13 18:26:03 +0000 |
---|---|---|
committer | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2010-05-13 18:26:03 +0000 |
commit | dc0eaef318d854ba1994f761b65fb6be5f7b9433 (patch) | |
tree | b670676c89889c302f331534da5c8e4f9a216b8d /libavfilter | |
parent | 40914d97ccf78ec26eabc9150fc6180ebce9dcd9 (diff) | |
download | ffmpeg-dc0eaef318d854ba1994f761b65fb6be5f7b9433.tar.gz |
Make av_parse_color() return AVERROR(EINVAL) rather than -1.
Originally committed as revision 23120 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavfilter')
-rw-r--r-- | libavfilter/parseutils.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavfilter/parseutils.c b/libavfilter/parseutils.c index 222ac73031..9a7eef08cd 100644 --- a/libavfilter/parseutils.c +++ b/libavfilter/parseutils.c @@ -231,7 +231,7 @@ int av_parse_color(uint8_t *rgba_color, const char *color_string, void *log_ctx) if (*tail || (len != 8 && len != 10)) { av_log(log_ctx, AV_LOG_ERROR, "Invalid 0xRRGGBB[AA] color string: '%s'\n", color_string); - return -1; + return AVERROR(EINVAL); } if (len == 10) { rgba_color[3] = rgba; @@ -248,7 +248,7 @@ int av_parse_color(uint8_t *rgba_color, const char *color_string, void *log_ctx) color_table_compare); if (!entry) { av_log(log_ctx, AV_LOG_ERROR, "Cannot find color '%s'\n", color_string); - return -1; + return AVERROR(EINVAL); } memcpy(rgba_color, entry->rgba_color, 4); } |