|
|
@ -3683,6 +3683,16 @@ bool CPhoneDevice::PostProcessPhoto(const PHOTO_INFO& photoInfo, const vector<ID
|
|
|
|
if (res/* && imgFileSize > 0*/)
|
|
|
|
if (res/* && imgFileSize > 0*/)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
res = (rename(tmpPath.c_str(), fullPath.c_str()) == 0);
|
|
|
|
res = (rename(tmpPath.c_str(), fullPath.c_str()) == 0);
|
|
|
|
|
|
|
|
if (res)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
imgFileSize = getFileSize(tmpPath);
|
|
|
|
|
|
|
|
if (imgFileSize == 0)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
XYLOG(XYLOG_SEVERITY_ERROR, "Empty File after rename %s", fullPath.c_str() + m_appPath.size());
|
|
|
|
|
|
|
|
res = false;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#else
|
|
|
|
#else
|
|
|
|
bool res = cv::imwrite(fullPath.c_str(), mat, params);
|
|
|
|
bool res = cv::imwrite(fullPath.c_str(), mat, params);
|
|
|
|