mirror of
https://github.com/loot/libloot.git
synced 2026-07-27 14:16:01 -07:00
Fixed a C string lifetime-related bug.
This commit is contained in:
@@ -55,8 +55,9 @@ namespace loot {
|
||||
}
|
||||
|
||||
const char * gameLocalDataPath = nullptr;
|
||||
if (!gameLocalAppData.empty())
|
||||
gameLocalDataPath = gameLocalAppData.string().c_str();
|
||||
string tempPathString = gameLocalAppData.string();
|
||||
if (!tempPathString.empty())
|
||||
gameLocalDataPath = tempPathString.c_str();
|
||||
|
||||
// If the handle has already been initialised, close it and open another.
|
||||
if (_gh != nullptr) {
|
||||
|
||||
Reference in New Issue
Block a user