Fix T92576: Crash switching from Asset Browser to File Brower
The asset catalog filtering data needs to be cleared when with the other asset library data of the file list. This is done when changing between asset and file browser (and in other cases).
This commit is contained in:
parent
e1db6dc11b
commit
d18d87d3e7
Notes:
blender-bot
2023-02-13 17:17:33 +01:00
Referenced by issue #92576, Crash switching from Asset Browser to File Brower
|
@ -1911,6 +1911,7 @@ static void filelist_clear_asset_library(FileList *filelist)
|
|||
{
|
||||
/* The AssetLibraryService owns the AssetLibrary pointer, so no need for us to free it. */
|
||||
filelist->asset_library = NULL;
|
||||
file_delete_asset_catalog_filter_settings(&filelist->filter_data.asset_catalog_filter);
|
||||
}
|
||||
|
||||
void filelist_clear_ex(struct FileList *filelist,
|
||||
|
@ -2010,7 +2011,6 @@ void filelist_free(struct FileList *filelist)
|
|||
filelist->selection_state = NULL;
|
||||
}
|
||||
|
||||
file_delete_asset_catalog_filter_settings(&filelist->filter_data.asset_catalog_filter);
|
||||
MEM_SAFE_FREE(filelist->asset_library_ref);
|
||||
|
||||
memset(&filelist->filter_data, 0, sizeof(filelist->filter_data));
|
||||
|
|
Loading…
Reference in New Issue