]> git.sesse.net Git - mlt/commitdiff
Fix possible null pointer dereference (coverity-1026784).
authorDan Dennedy <dan@dennedy.org>
Sun, 2 Jun 2013 21:05:45 +0000 (14:05 -0700)
committerDan Dennedy <dan@dennedy.org>
Sun, 2 Jun 2013 21:54:42 +0000 (14:54 -0700)
src/framework/mlt_animation.c

index e53fdcaa4497e1648bb543ebd7238d7a1d3e3521..5928b0d3cb1bded514866cb1254cf8eb1650ecea 100644 (file)
@@ -693,8 +693,9 @@ char *mlt_animation_serialize( mlt_animation self )
                if ( self->data )
                        free( self->data );
                self->data = ret;
+               ret = strdup( ret );
        }
-       return strdup( ret );
+       return ret;
 }
 
 /** Close the animation and deallocate all of its resources.