UDataTable::RemoveRow(FName RowName) is crashing after updating to 5.6. It looks to be related to DATATABLE_CHANGE_SCOPE_SINGLE_ROW running HandleDataTableChanged after the row has been removed and deleted, failing on the lookup:
FTableRowBase* CurRow = reinterpret_cast<FTableRowBase*>(RowMap[ChangedRowName]);
We added a call to RowMap.Contains(ChangedRowName) to guard from the crash, but the DATATABLE_CHANGE_SCOPE_SINGLE_ROW object might need to be reworked to notify before removal, do the previous notify all or not notify at all.
Steps to Reproduce
Make a call to UDataTable::RemoveRow(FName RowName).
Hi Jacques,
Sorry about the delay. I’m looking into this now and should get back to you soon.
Best regards,
Vitor
Hi Jacques,
I was able to reproduce this crash here, and it seems to have been introduced by CL 40129784. Your fix seems appropriate, although for performance you could also have replaced the operator (which is checked for key existence) by a non-checked accessor to avoid a double lookup.
I have created an internal bug report for this issue. You should be able to track it here once the engine devs mark it as public: UE-296335.
Best regards,
Vitor