Originally committed as revision 23120 to svn://svn.ffmpeg.org/ffmpeg/trunk
Unified · Split
| @@ -231,7 +231,7 @@ int av_parse_color(uint8_t *rgba_color, const char *color_string, void *log_ctx) · 230 unmodified lines | ||
| 231 | 231 | |
| 232 | 232 | if (*tail || (len != 8 && len != 10)) { |
| 233 | 233 | av_log(log_ctx, AV_LOG_ERROR, "Invalid 0xRRGGBB[AA] color string: '%s'\n", color_string); |
| 234 | − return -1; | |
| 234 | + return AVERROR(EINVAL); | |
| 235 | 235 | } |
| 236 | 236 | if (len == 10) { |
| 237 | 237 | rgba_color[3] = rgba; |
| @@ -248,7 +248,7 @@ int av_parse_color(uint8_t *rgba_color, const char *color_string, void *log_ctx) · 10 unmodified lines | ||
| 248 | 248 | color_table_compare); |
| 249 | 249 | if (!entry) { |
| 250 | 250 | av_log(log_ctx, AV_LOG_ERROR, "Cannot find color '%s'\n", color_string); |
| 251 | − return -1; | |
| 251 | + return AVERROR(EINVAL); | |
| 252 | 252 | } |
| 253 | 253 | memcpy(rgba_color, entry->rgba_color, 4); |
| 254 | 254 | } |