In the existing code, the remote surface was cleared here.
However, in general, WIDGET_INSTANCE_EVENT_FAULT is called later, so we can clear it at that time.
Currently, if we clear in advance at this point, a crash may occur in the process of restarting the widget.
(It seems that the malloc issue occurs in the process of replacing the existing callback)
Therefore, to avoid this crash, delete the part that was cleared at this point.
Change-Id: I4f54546a36295ae26382a39bb13913153b32cf69
static void OnSurfaceRemoved( const char *appid, const char *instance_id, const int pid, void *data )
{
- Dali::WidgetView::Internal::WidgetView* widgetView = static_cast< Dali::WidgetView::Internal::WidgetView* >( data );
-
- if( widgetView && !widgetView->IsWidgetFaulted() )
- {
- widgetView->CloseRemoteSurface();
- }
}
} // unnamed namespace