[Bf-blender-cvs] [d18d87d3e7d] master: Fix T92576: Crash switching from Asset Browser to File Brower
Julian Eisel
noreply at git.blender.org
Fri Oct 29 16:00:55 CEST 2021
Commit: d18d87d3e7d381124f91c2230eb447ff5b001c27
Author: Julian Eisel
Date: Fri Oct 29 15:59:03 2021 +0200
Branches: master
https://developer.blender.org/rBd18d87d3e7d381124f91c2230eb447ff5b001c27
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).
===================================================================
M source/blender/editors/space_file/filelist.c
===================================================================
diff --git a/source/blender/editors/space_file/filelist.c b/source/blender/editors/space_file/filelist.c
index a1b1c8cc363..a73fa2b9740 100644
--- a/source/blender/editors/space_file/filelist.c
+++ b/source/blender/editors/space_file/filelist.c
@@ -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));
More information about the Bf-blender-cvs
mailing list