e60e619655
Background library loading threads call GetRow() through loadFromScope(), which writes to m_rowCache concurrently with the main thread clearing it in loadTables(). The unsynchronized access corrupts the map's red-black tree, causing a double-free crash when switching projects. Add m_rowCacheMutex to protect all m_rowCache accesses. Also replace std::tie with std::make_tuple to avoid unnecessary temporary conversions, and use a single find() instead of contains() followed by at().