mirror of
https://github.com/reactos/CMake.git
synced 2024-11-27 13:30:39 +00:00
cmake-gui: Fix use-after-free in Open-possible check
Fix `QCMake::checkOpenPossible` to copy `toLocal8Bit().data()` before its lifetime expires.
This commit is contained in:
parent
e3185e3d1b
commit
ecc0086bfc
@ -486,7 +486,7 @@ void QCMake::setWarnUnusedMode(bool value)
|
||||
|
||||
void QCMake::checkOpenPossible()
|
||||
{
|
||||
auto data = this->BinaryDirectory.toLocal8Bit().data();
|
||||
std::string data = this->BinaryDirectory.toLocal8Bit().data();
|
||||
auto possible = this->CMakeInstance->Open(data, true);
|
||||
emit openPossible(possible);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user