mirror of
https://gitlab.com/pholy/OSCAR-code.git
synced 2025-04-05 10:40:42 +00:00
Fix use-after-free in Profile::UnloadMachineData
This commit is contained in:
parent
f05cc5fbc5
commit
6b7fe4c8f2
@ -581,16 +581,17 @@ void Profile::UnloadMachineData()
|
||||
return;
|
||||
}
|
||||
|
||||
for (auto & day : daylist) {
|
||||
delete day;
|
||||
}
|
||||
daylist.clear();
|
||||
|
||||
for (auto & mach : m_machlist) {
|
||||
mach->saveSessionInfo();
|
||||
mach->sessionlist.clear();
|
||||
mach->day.clear();
|
||||
}
|
||||
|
||||
for (auto & day : daylist) {
|
||||
delete day;
|
||||
}
|
||||
daylist.clear();
|
||||
|
||||
removeLock();
|
||||
}
|
||||
void Profile::LoadMachineData(ProgressDialog *progress)
|
||||
|
Loading…
Reference in New Issue
Block a user