]> git.sesse.net Git - mlt/commitdiff
producer_framebuffer.c: bugfix segfault in construction with null argument.
authorddennedy <ddennedy@d19143bc-622f-0410-bfdd-b5b2a6649095>
Sat, 8 Nov 2008 20:02:43 +0000 (20:02 +0000)
committerddennedy <ddennedy@d19143bc-622f-0410-bfdd-b5b2a6649095>
Sat, 8 Nov 2008 20:02:43 +0000 (20:02 +0000)
git-svn-id: https://mlt.svn.sourceforge.net/svnroot/mlt/trunk/mlt@1228 d19143bc-622f-0410-bfdd-b5b2a6649095

src/modules/kdenlive/producer_framebuffer.c

index d028eaac916b00a6971a9500d1da1836ba327bcd..97edd6dca922e63e8599f32139c0f83ffc937ea3 100644 (file)
@@ -194,7 +194,7 @@ static int producer_get_frame( mlt_producer this, mlt_frame_ptr frame, int index
 
 mlt_producer producer_framebuffer_init( mlt_profile profile, mlt_service_type type, const char *id, char *arg )
 {
-
+       if ( !arg ) return NULL;
        mlt_producer this = NULL;
        this = calloc( 1, sizeof( struct mlt_producer_s ) );
        mlt_producer_init( this, NULL );
@@ -236,7 +236,6 @@ mlt_producer producer_framebuffer_init( mlt_profile profile, mlt_service_type ty
 
        if (speed == 0.0) speed = 1.0;
 
-
        if ( this != NULL && real_producer != NULL)
        {
                // Get the properties of this producer