mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-06-24 16:47:57 +00:00
1877871be0
std::string_views are created pointing to vector-owned strings, but
those strings can use Short String Optimisation (storing the data
inline, i.e. in vector memory). When the vector is resized, the strings
are moved and those string_views now point to invalid memory.
To fix it, use std::deque which does not invalidate pointers on
push_back.
Fixes 5d2be02f68.
Reviewed By: vladislavbelov
Fixes #5950
Differential Revision: https://code.wildfiregames.com/D3441
This was SVN commit r24742.