if (m_result == ConfigureResult::Failed_InvalidConfig) {
ThrowMsg(Jobs::WidgetInstall::Exceptions::WidgetConfigFileInvalid,
"invalid config");
+ } else if (m_result == ConfigureResult::Failed_OpenZipError) {
+ ThrowMsg(Jobs::WidgetInstall::Exceptions::OpenZipFailed,
+ "can't open wgt file");
+ } else if (m_result == ConfigureResult::Failed_UnzipError) {
+ ThrowMsg(Jobs::WidgetInstall::Exceptions::ExtractFileFailed,
+ "can't extract wgt file");
} else if (m_result == ConfigureResult::Failed_LowerVersion) {
ThrowMsg(Jobs::WidgetInstall::Exceptions::PackageLowerVersion,
"package version is lower than installed version");
// Any error in acecheck while update will break widget
AddTask(new TaskSmack(m_installerContext));
AddTask(new TaskRemoveBackupFiles(m_installerContext));
- } else if (result >= ConfigureResult::Failed &&
- result <= ConfigureResult::Failed_NotSupportRDSUpdate) {
+ } else {
// Installation is not allowed to proceed due to widget update policy
LogWarning("Configure installation failed!");
AddTask(new InstallerTaskFail(result));
- } else {
- Assert(false && "Invalid configure result!");
}
}
// Configure installation
result = ConfigureInstallation(widgetPath, configData, tempDir);
}
+ Catch(Exceptions::OpenZipFailed)
+ {
+ LogError("Failed to unzip for widget");
+ result = ConfigureResult::Failed_OpenZipError;
+ }
Catch(Exceptions::ExtractFileFailed)
{
- LogError("Failed to create temporary path for widget");
- result = ConfigureResult::Failed_InvalidConfig;
+ LogError("Failed to unzip for widget");
+ result = ConfigureResult::Failed_UnzipError;
+ }
+ Catch(Exceptions::DrmDecryptFailed)
+ {
+ LogError("Failed to unzip for widget");
+ result = ConfigureResult::Failed_DrmError;
}
return result;