Fix: Use after free in spreadsheet attribute column ID
A temporary string was created in the attribute_foreach callback and used in a map at a higher scope. When the callback finished, the string went out of scope, was freed, then the elements in the set pointed to freed memory.
This commit is contained in:
parent
7c7348f78d
commit
e6fa74ffed
Notes:
blender-bot
2023-02-14 05:28:01 +01:00
Referenced by issue #89045, VSE playback periodically refuses to work (Pulseaudio, OpenAL seems fine)
|
@ -54,8 +54,7 @@ void GeometryDataSource::foreach_default_column_ids(
|
|||
return true;
|
||||
}
|
||||
SpreadsheetColumnID column_id;
|
||||
std::string name = attribute_id.name();
|
||||
column_id.name = (char *)name.c_str();
|
||||
column_id.name = (char *)attribute_id.name().data();
|
||||
fn(column_id);
|
||||
return true;
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue