repair vaapi encode_frame, fix segv on unreadable asset, update crop resource icon...
[goodguy/cinelerra.git] / cinelerra-5.1 / cinelerra / awindowgui.C
index 091fd140e65e75faed556758da8791ea64ef666c..66e69c3bd873d769092624af39d32cfb95b377d1 100644 (file)
@@ -121,8 +121,7 @@ VFrame *AssetVIcon::frame()
 {
        AssetVIconThread *avt = picon->gui->vicon_thread;
        Asset *asset = (Asset *)picon->indexable;
-       if( !asset )
-               return *images[0];
+       if( !asset ) return vframes()>0 ? (VFrame*)*images[0] : 0;
        if( !asset->video_data && audio_data && audio_size && length > 0 ) {
                if( !temp ) temp = new VFrame(0, -1, w, h, BC_RGB888, -1);
                temp->clear_frame();