fixing crash when running with asan
This commit is contained in:
parent
e83bd11891
commit
30bb8ca2fd
@ -422,7 +422,7 @@ XMLNode *FileManager::createXMLTreeFromString(const std::string & content)
|
||||
{
|
||||
char *b = new char[content.size()];
|
||||
memcpy(b, content.c_str(), content.size());
|
||||
io::IReadFile * ireadfile = m_file_system->createMemoryReadFile(b, strlen(b), "tempfile", true);
|
||||
io::IReadFile * ireadfile = m_file_system->createMemoryReadFile(b, content.size(), "tempfile", true);
|
||||
io::IXMLReader * reader = m_file_system->createXMLReader(ireadfile);
|
||||
XMLNode* node = new XMLNode(reader);
|
||||
reader->drop();
|
||||
@ -791,7 +791,7 @@ void FileManager::checkAndCreateConfigDir()
|
||||
{
|
||||
m_user_config_dir = getenv("HOME");
|
||||
checkAndCreateDirectory(m_user_config_dir);
|
||||
|
||||
|
||||
m_user_config_dir += "/.config";
|
||||
if(!checkAndCreateDirectory(m_user_config_dir))
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user