[Tizen-submit] 3396: Changes to Tizen:2.1:Main/osp-app-service

noreply at tizen.org noreply at tizen.org
Fri Apr 26 14:58:29 GMT 2013


Hi,
Jinkun Jang have made the following changes to osp-app-service in project Tizen:2.1:Main. Please review and accept ASAP.

Thank You,

[This message was auto-generated]

---

Request: #3396

  submit:       Tizen:2.1:Main:build/osp-app-service(cleanup) -> Tizen:2.1:Main


Message:
Submitter: Jinkun Jang <jinkun.jang at samsung.com>
Comments: upload latest
Git project: framework/osp/app-service
Tag: submit/tizen_2.1/20130426.145857
Commit: 2084966 Merge "Apply changing bluetooth mode by using async func" into tizen_2.1

State:   new        2013-04-26T07:29:07 tizenrobot
Comment: <no comment>
spec files:
-----------
--- osp-app-service.spec
+++ osp-app-service.spec
@@ -1,8 +1,8 @@
 Name:		osp-app-service
 Summary:	osp application service
 Version:	1.2.1.0
-Release:	8
-VCS:        framework/osp/app-service#2.1_release-0-g1445c01
+Release:	9
+VCS:        framework/osp/app-service#submit/tizen_2.1/20130426.145857-0-g2084966
 Group:		System/Libraries
 License:	Apache-2.0 or Flora
 Source0:	%{name}-%{version}.tar.gz

other changes:
--------------

++++++ osp-app-service-1.2.1.0.tar.gz
--- /packaging/osp-app-service.spec
+++ /packaging/osp-app-service.spec
@@ -1,7 +1,7 @@
 Name:		osp-app-service
 Summary:	osp application service
 Version:	1.2.1.0
-Release:	8
+Release:	9
 Group:		System/Libraries
 License:	Apache-2.0 or Flora
 Source0:	%{name}-%{version}.tar.gz
--- /plugins/message-condition-handler/MessageConditionHandler.cpp
+++ /plugins/message-condition-handler/MessageConditionHandler.cpp
@@ -436,29 +436,26 @@
 	_MessageConditionHandler* pHandler = dynamic_cast<_MessageConditionHandler*>(pAppLaunchCondition->GetUserData());
 	SysTryReturnVoidResult(NID_APP, pHandler != null, E_INVALID_STATE, "user data is null");
 
-	// get body
-	int size = sizeof(char) * bodyLength;
-	char* pTemp = (char*)malloc(size + 1);
-	SysTryReturnVoidResult(NID_APP, pTemp != null, E_OUT_OF_MEMORY, "Memory allocation failed.");
-	memcpy(pTemp, pBody, size);
-	pTemp[size] = '\0';
-	unique_ptr<char[], _CharDeleter> pTempBody(pTemp);
+	ByteBuffer *msgBody = new ByteBuffer();
+	SysTryReturnVoidResult(NID_APP, msgBody != null, E_OUT_OF_MEMORY, "Failed to add a BODY to the hash map.");	
+	msgBody->Construct(bodyLength);
+	msgBody->SetArray((byte*) pBody, 0, bodyLength);
+	msgBody->SetPosition(0);
 
 	result r = E_SUCCESS;
-
-	// hash map
 	HashMap map(SingleObjectDeleter);
+
 	r = map.Construct();
 	SysTryReturnVoidResult(NID_APP, r == E_SUCCESS, r, "Failed to construct a hash map.");
-
 	r = map.Add(new String(L"TYPE"), new String(L"WAPPUSH"));
 	SysTryReturnVoidResult(NID_APP, r == E_SUCCESS, r, "Failed to add a TYPE to the hash map.");
 	r = map.Add(new String(L"HEADER"), new String(pHeader));
 	SysTryReturnVoidResult(NID_APP, r == E_SUCCESS, r, "Failed to add a HEADER to the hash map.");
-	r = map.Add(new String(L"BODY"), new String(pTempBody.get()));
+	r = map.Add(new String(L"BODY"), msgBody);
 	SysTryReturnVoidResult(NID_APP, r == E_SUCCESS, r, "Failed to add a BODY to the hash map.");
 
 	pHandler->Fire(*pAppLaunchCondition, &map);
+	
 }
 
 Tizen::Base::DateTime
--- /src/AppService.cpp
+++ /src/AppService.cpp
@@ -496,18 +496,19 @@
 	IList* pList = _PackageManagerImpl::GetInstance()->GetPackageInfoListN(packageFilterMap);
 	if (pList)
 	{
-			   for (int i = 0; i < pList->GetCount(); i++)
-			   {
-						 PackageInfo* pPackageInfo = dynamic_cast <PackageInfo*>(pList->GetAt(i));
-						 if (pPackageInfo)
-						 {
-						   SysLog(NID_APP, "[%d]-------------------------------------------------------", i+1);
-						   SysLog(NID_APP, "Id [%ls]", pPackageInfo->GetId().GetPointer());
-						   SysLog(NID_APP, "Name [%ls]", pPackageInfo->GetDisplayName().GetPointer());
-						   AppService::GetAppServiceInstance()->OnPackageInstallationCompleted(pPackageInfo->GetId(), PACKAGE_INSTALLATION_RESULT_SUCCESS);

Please refer to OBS webUI for more details about this SR.


More information about the Tizen-submit mailing list