fix return value for removeTmpDir

This commit is contained in:
Jimmy Ohn 2020-01-06 09:44:33 +09:00
parent c9518f345f
commit f9b33f305d
2 changed files with 7 additions and 3 deletions

View File

@ -394,7 +394,10 @@ bool SMTPFileSystem::exec()
}
m_device.disconnect();
m_tmp_files_pool.removeTmpDir();
if (!m_tmp_files_pool.removeTmpDir()) {
logerr("Can not remove a temporary directory.\n");
return false;
}
return true;
}

View File

@ -58,8 +58,9 @@ std::string TmpFilesPool::makeTmpPath(const std::string &path_device) const
bool TmpFilesPool::createTmpDir()
{
removeTmpDir();
return smtpfs_create_dir(m_tmp_dir);
if (removeTmpDir())
return smtpfs_create_dir(m_tmp_dir);
return false;
}
bool TmpFilesPool::removeTmpDir()