]> git.sesse.net Git - mlt/commitdiff
Fix corruption in color producer (3288984)
authorDan Dennedy <dan@dennedy.org>
Tue, 19 Apr 2011 00:18:26 +0000 (17:18 -0700)
committerDan Dennedy <dan@dennedy.org>
Tue, 19 Apr 2011 00:18:26 +0000 (17:18 -0700)
src/modules/core/producer_colour.c

index 60d999463a2f77edde238f4f8e6feb93bf3c1553..e5188fa7c056df41c9e8ac7e33b4bee45ae02c13 100644 (file)
@@ -118,8 +118,10 @@ static int producer_get_image( mlt_frame frame, uint8_t **buffer, mlt_image_form
        // Parse the colour
        if ( now && strchr( now, '/' ) )
        {
-               now = strrchr( now, '/' ) + 1;
+               now = strdup( strrchr( now, '/' ) + 1 );
                mlt_properties_set( producer_props, "resource", now );
+               free( now );
+               now = mlt_properties_get( producer_props, "resource" );
        }
        rgba_color color = parse_color( now, mlt_properties_get_int( producer_props, "resource" ) );