[FFmpeg-cvslog] r23120 - trunk/libavfilter/parseutils.c

stefano subversion
Thu May 13 20:26:03 CEST 2010


Author: stefano
Date: Thu May 13 20:26:03 2010
New Revision: 23120

Log:
Make av_parse_color() return AVERROR(EINVAL) rather than -1.

Modified:
   trunk/libavfilter/parseutils.c

Modified: trunk/libavfilter/parseutils.c
==============================================================================
--- trunk/libavfilter/parseutils.c	Thu May 13 20:06:44 2010	(r23119)
+++ trunk/libavfilter/parseutils.c	Thu May 13 20:26:03 2010	(r23120)
@@ -231,7 +231,7 @@ int av_parse_color(uint8_t *rgba_color, 
 
         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, 
                                           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);
     }



More information about the ffmpeg-cvslog mailing list