{
// Clone our image
uint8_t *copy = mlt_pool_alloc( size );
- memcpy( copy, image, size );
+ if ( copy != NULL )
+ memcpy( copy, image, size );
// We're going to pass the copy on
image = copy;
else if ( text != NULL && strcmp( text, "" ) != 0 )
pango_layout_set_text( layout, text, strlen( text ) );
else
- return NULL;
+ pango_layout_set_text( layout, " ", 2 );
pango_layout_get_pixel_size( layout, &w, &h );
pixbuf = gdk_pixbuf_new( GDK_COLORSPACE_RGB, TRUE /* has alpha */, 8, w + 2 * pad, h + 2 * pad );