#include "InstallerUtil.h"
-#define OSP_INSTALLER_VERSION "version=[20130326.2]"
+#define OSP_INSTALLER_VERSION "version=[20130328.1]"
#define DIR_BIN L"/bin"
#define DIR_INFO L"/info"
,__pSubModeAppControlDataList(null)
,__pNameList(null)
,__pFeatureList(null)
-,__pLaunchConditionList(null)
,__pNotificationMap(null)
,__pMetadataMap(null)
+,__pLaunchConditionList(null)
,__feature(0)
,__isSubMode(false)
,__legacyAppControls(false)
delete __pFeatureList;
}
- if (__pLaunchConditionList)
- {
- __pLaunchConditionList->RemoveAll();
- delete __pLaunchConditionList;
- }
-
if (__pNotificationMap)
{
__pNotificationMap->RemoveAll();
__pMetadataMap->RemoveAll();
delete __pMetadataMap;
}
+
+ if (__pLaunchConditionList)
+ {
+ __pLaunchConditionList->RemoveAll();
+ delete __pLaunchConditionList;
+ }
}
InstallerError
r = __pFeatureList->Construct();
TryReturn(!IsFailed(r), INSTALLER_ERROR_OUT_OF_MEMORY, "__pFeatureList->Construct() failed.");
- __pLaunchConditionList = new (std::nothrow) HashMap(SingleObjectDeleter);
- TryReturn(__pLaunchConditionList, INSTALLER_ERROR_OUT_OF_MEMORY, "__pLaunchConditionList is null.");
- r = __pLaunchConditionList->Construct();
- TryReturn(!IsFailed(r), INSTALLER_ERROR_OUT_OF_MEMORY, "__pLaunchConditionList->Construct() failed.");
-
__pNotificationMap = new (std::nothrow) HashMap(SingleObjectDeleter);
TryReturn(__pNotificationMap, INSTALLER_ERROR_OUT_OF_MEMORY, "__pNotificationMap is null.");
r = __pNotificationMap->Construct();
r = __pMetadataMap->Construct();
TryReturn(!IsFailed(r), INSTALLER_ERROR_OUT_OF_MEMORY, "__pMetadataMap->Construct() failed.");
+ __pLaunchConditionList = new (std::nothrow) MultiHashMap(SingleObjectDeleter);
+ TryReturn(__pLaunchConditionList, INSTALLER_ERROR_OUT_OF_MEMORY, "__pLaunchConditionList is null.");
+ r = __pLaunchConditionList->Construct();
+ TryReturn(!IsFailed(r), INSTALLER_ERROR_OUT_OF_MEMORY, "__pLaunchConditionList->Construct() failed.");
+
return INSTALLER_ERROR_NONE;
}
Tizen::Base::Collection::HashMap* __pNameList;
Tizen::Base::Collection::HashMap* __pFeatureList;
- Tizen::Base::Collection::HashMap* __pLaunchConditionList;
Tizen::Base::Collection::HashMap* __pNotificationMap;
Tizen::Base::Collection::HashMap* __pMetadataMap;
+ Tizen::Base::Collection::MultiHashMap* __pLaunchConditionList;
+
int __feature;
bool __isSubMode;
TryReturn(pAppData->__pLaunchConditionList, E_SYSTEM, "__pLaunchConditionList is null.");
result r = E_SUCCESS;
- HashMap* pList = pAppData->__pLaunchConditionList;
+ MultiHashMap* pList = pAppData->__pLaunchConditionList;
std::unique_ptr< IMapEnumerator > pEnum(pList->GetMapEnumeratorN());
TryReturn(pEnum, false, "GetMapEnumeratorN() failed. [%s]", GetErrorMessage(GetLastResult()));
PackageCheckStep::OnStatePackageCheck(void)
{
InstallerError error = INSTALLER_ERROR_NONE;
+ result r = E_SUCCESS;
String tempDir;
if (__pContext->__storage == INSTALLATION_STORAGE_INTERNAL)
if (File::IsFileExist(DIR_OSP_APPLICATIONS_TEMP) == false)
{
- result r = E_SUCCESS;
r = Directory::Create(DIR_OSP_APPLICATIONS_TEMP, false);
TryReturn(!IsFailed(r), INSTALLER_ERROR_INTERNAL_STATE, "Directory::Create() failed");
}
unzipper.Construct(packagePath);
AppLog("UnzipTo(manifest.xml) - START");
- unzipper.UnzipTo(tempDir, L"info/manifest.xml");
- unzipper.UnzipTo(tempDir, L"signature1.xml");
- unzipper.UnzipTo(tempDir, L"author-signature.xml");
+
+ r = unzipper.UnzipTo(tempDir, L"info/manifest.xml");
+ TryReturn(!IsFailed(r), INSTALLER_ERROR_PACKAGE_INVALID, "UnzipTo(manifest.xml) failed.");
+
+ r = unzipper.UnzipTo(tempDir, L"signature1.xml");
+ //TryReturn(!IsFailed(r), INSTALLER_ERROR_PACKAGE_INVALID, "UnzipTo(signature1.xml) failed.");
+
+ r = unzipper.UnzipTo(tempDir, L"author-signature.xml");
+ //TryReturn(!IsFailed(r), INSTALLER_ERROR_PACKAGE_INVALID, "UnzipTo(author-signature.xml) failed.");
+
AppLog("UnzipTo(manifest.xml) - END");
if ((File::IsFileExist(__pContext->GetSignatureXmlPath()) == true) &&
}
AppLog("UnzipTo - START");
- unzipper.UnzipTo(newInstallPath);
+ r = unzipper.UnzipTo(newInstallPath);
+ TryReturn(!IsFailed(r), INSTALLER_ERROR_OUT_OF_STORAGE, "UnzipTo(%ls) failed.", newInstallPath.GetPointer());
AppLog("UnzipTo - END");
// GoNextState();