summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeesun Kim <iamjs.kim@samsung.com>2017-11-10 11:09:43 +0900
committerJeesun Kim <iamjs.kim@samsung.com>2017-11-10 11:10:08 +0900
commit6e7285b37370fcd3aec822214a80232ec46da42e (patch)
tree25b6eee448758f2335dab6d70e3cb2180562f0b1
parent53489eb6b10de13ea2014231b208a1c0c1a27a7e (diff)
downloadmsg-service-accepted/tizen_3.0_mobile.tar.gz
msg-service-accepted/tizen_3.0_mobile.tar.bz2
msg-service-accepted/tizen_3.0_mobile.zip
Change-Id: I521208eaa61693f743f1194c1b8897823c4ccdeb
-rwxr-xr-xutils/MsgUtilFunction.cpp17
1 files changed, 9 insertions, 8 deletions
diff --git a/utils/MsgUtilFunction.cpp b/utils/MsgUtilFunction.cpp
index 392e088..b7f0bf2 100755
--- a/utils/MsgUtilFunction.cpp
+++ b/utils/MsgUtilFunction.cpp
@@ -1286,14 +1286,6 @@ void* _msg_launch_app(void *data)
msg_error_t msg_launch_app(const char *app_id, bundle *bundle_data)
{
- msg_launch_app_data *data = (msg_launch_app_data *)calloc(1, sizeof(msg_launch_app_data));
- if (data == NULL) {
- MSG_ERR("Memory alloc failed!");
- return MSG_ERR_MEMORY_ERROR;
- }
-
- data->app_id = g_strdup(app_id);
- data->bundle_data = bundle_dup(bundle_data);
pthread_t thd;
pthread_attr_t attr;
@@ -1307,6 +1299,15 @@ msg_error_t msg_launch_app(const char *app_id, bundle *bundle_data)
return MSG_ERR_UNKNOWN;
}
+ msg_launch_app_data *data = (msg_launch_app_data *)calloc(1, sizeof(msg_launch_app_data));
+ if (data == NULL) {
+ MSG_ERR("Memory alloc failed!");
+ return MSG_ERR_MEMORY_ERROR;
+ }
+
+ data->app_id = g_strdup(app_id);
+ data->bundle_data = bundle_dup(bundle_data);
+
if (pthread_create(&thd, &attr, &_msg_launch_app, data) < 0) {
MSG_ERR("pthread_create() error");
}