129668 【备份还原】创建Ghost镜像到空间不足的U盘中,不会提示“空间不足”,创建结束后U盘目录下有ghost文件夹里面没有镜像文件(日志中显示剩余空间不足,但是没有上报前端)

This commit is contained in:
zhaominyong 2022-07-14 13:38:03 +08:00
parent c941742966
commit 328bf1a4ea
3 changed files with 3 additions and 6 deletions

View File

@ -78,8 +78,7 @@ bool CustomizeGhostImageProxy::checkEnvEx()
}
// 4、校验空间是否充足
QFileInfo backup(m_srcPath);
qint64 itotalSize = backup.size();
qint64 itotalSize = Utils::getDirOrFileSize(m_srcPath);
m_destPath = m_backupWrapper.m_prefixDestPath + GHOST_PATH;
m_destPath.replace("//", "/");
Utils::mkpath(m_destPath);

View File

@ -58,8 +58,7 @@ bool GhostImageProxy::checkEnvEx()
emit checkResult(int(BackupResult::GHOST_SRC_DIRECTORY_IS_NOT_EXIST));
return false;
}
QFileInfo backup(dataPath);
qint64 itotalSize = backup.size();
qint64 itotalSize = Utils::getDirOrFileSize(dataPath);
// 4、校验空间大小是否充足
m_destPath = Utils::getSysRootPath() + GHOST_PATH;

View File

@ -73,8 +73,7 @@ bool UDiskGhostImageProxy::checkEnvEx()
emit checkResult(int(BackupResult::GHOST_SRC_DIRECTORY_IS_NOT_EXIST));
return false;
}
QFileInfo backup(dataPath);
qint64 itotalSize = backup.size();
qint64 itotalSize = Utils::getDirOrFileSize(dataPath);
// 4、校验移动设备情况空间大小、文件格式、挂载模式等
QString backupPath(m_backupWrapper.m_prefixDestPath);