Add the mmsvc_core_get_atomic_uint function 05/44805/1 submit/tizen/20150728.084621
authorHyongtaek Lim <hyongtaek.lim@samsung.com>
Tue, 28 Jul 2015 04:47:14 +0000 (13:47 +0900)
committerHyongtaek Lim <hyongtaek.lim@samsung.com>
Tue, 28 Jul 2015 04:48:10 +0000 (13:48 +0900)
Signed-off-by: Hyongtaek Lim <hyongtaek.lim@samsung.com>
Change-Id: I06a82ce3fa8d23896b5c4231a8fd5a017bdec620

include/mmsvc_core.h
src/mmsvc_core.c

index fbdd71a..75fd5b0 100644 (file)
@@ -42,6 +42,7 @@ void *mmsvc_core_client_get_cust_data(Client client);
 char *mmsvc_core_client_get_msg(Client client);
 int mmsvc_core_client_get_capi(Client client);
 void mmsvc_core_worker_exit(Client client);
+unsigned mmsvc_core_get_atomic_uint(void);
 
 #ifdef __cplusplus
 }
index 18efecf..98ebbb1 100644 (file)
@@ -499,3 +499,12 @@ void mmsvc_core_worker_exit(Client client)
        LOGD("Leave");
        g_thread_exit(NULL);
 }
+
+unsigned mmsvc_core_get_atomic_uint()
+{
+       static guint atom = 0;
+
+       g_atomic_int_inc(&atom);
+
+       return atom;
+}