Fix T42943: Crash with multiple calls to rna_info.BuildRNAInfo()
Thanks to @nesse for the fix
This commit is contained in:
parent
f0f1c7995b
commit
85f6fc501c
Notes:
blender-bot
2023-02-14 09:42:35 +01:00
Referenced by issue #42943, Crashes occur when rna_info.BuildRNAInfo() is called multiple times
|
@ -487,6 +487,12 @@ def GetInfoOperatorRNA(bl_rna):
|
|||
|
||||
|
||||
def BuildRNAInfo():
|
||||
|
||||
# needed on successive calls to prevent stale data access
|
||||
for cls in (InfoStructRNA, InfoFunctionRNA, InfoOperatorRNA, InfoPropertyRNA):
|
||||
cls.global_lookup.clear()
|
||||
del cls
|
||||
|
||||
# Use for faster lookups
|
||||
# use rna_struct.identifier as the key for each dict
|
||||
rna_struct_dict = {} # store identifier:rna lookups
|
||||
|
|
Loading…
Reference in New Issue