Remove macro for supporting old glib 23/268023/1
authorjh9216.park <jh9216.park@samsung.com>
Wed, 15 Dec 2021 04:17:24 +0000 (23:17 -0500)
committerjh9216.park <jh9216.park@samsung.com>
Wed, 15 Dec 2021 04:18:44 +0000 (23:18 -0500)
Change-Id: I9110134b840db4459f3554c423e557aa1450651e
Signed-off-by: jh9216.park <jh9216.park@samsung.com>
lib/alarm-lib.c
server/alarm-manager-db.c
server/alarm-manager.c
tool/alarmmgr_add_periodic_alarm_withcb.c
tool/alarmmgr_add_reference_periodic_alarm_withcb.c

index 5ef84f7..7c22c84 100644 (file)
@@ -438,13 +438,6 @@ static int __sub_init()
                return ALARMMGR_RESULT_SUCCESS;
        }
 
-#if !(GLIB_CHECK_VERSION(2, 32, 0))
-       g_thread_init(NULL);
-#endif
-#if !(GLIB_CHECK_VERSION(2, 36, 0))
-       g_type_init();
-#endif
-
        alarm_context.connection = g_bus_get_sync(G_BUS_TYPE_SYSTEM, NULL, &error);
        if (alarm_context.connection == NULL) {
                LOGE("g_bus_get_sync() is failed. error: %s", error->message);
@@ -1666,12 +1659,6 @@ EXPORT_API int alarmmgr_set_systime64_async(time_t new_time, alarm_set_time_cb_t
                                        result_cb, user_param))
                        return ERR_ALARM_SYSTEM_FAIL;
        } else {
-#if !(GLIB_CHECK_VERSION(2, 32, 0))
-               g_thread_init(NULL);
-#endif
-#if !(GLIB_CHECK_VERSION(2, 36, 0))
-               g_type_init();
-#endif
                param = g_try_new0(struct alarm_async_param_t, 1);
                if (param == NULL) {
                        LOGE("Failed to alloc param");
@@ -1717,12 +1704,6 @@ EXPORT_API int alarmmgr_set_systime_with_propagation_delay_async(struct timespec
                                        new_time, req_time, result_cb, user_param))
                        return ERR_ALARM_SYSTEM_FAIL;
        } else {
-#if !(GLIB_CHECK_VERSION(2, 32, 0))
-               g_thread_init(NULL);
-#endif
-#if !(GLIB_CHECK_VERSION(2, 36, 0))
-               g_type_init();
-#endif
                param = g_try_new0(struct alarm_async_param_t, 1);
                if (param == NULL) {
                        LOGE("Failed to alloc param");
index aed8b99..d8bb966 100644 (file)
@@ -23,9 +23,6 @@
 #include <sqlite3.h>
 #include <glib.h>
 #include <tzplatform_config.h>
-#if !GLIB_CHECK_VERSION(2, 31, 0)
-#include <glib/gmacros.h>
-#endif
 
 #include "alarm-manager-db.h"
 
index 27a25cf..ff24983 100644 (file)
 #include "alarm-manager-util.h"
 #include "alarm-manager-dbus.h"
 
-#if !GLIB_CHECK_VERSION(2, 31, 0)
-#include <glib/gmacros.h>
-#endif
-
 /* link path for timezone info */
 #define TIMEZONE_INFO_LINK_PATH        tzplatform_mkpath(TZ_SYS_ETC, "localtime")
 
@@ -3159,9 +3155,6 @@ out:
 
 void _alarm_initialize()
 {
-#if !(GLIB_CHECK_VERSION(2, 36, 0))
-       g_type_init();
-#endif
        time_t latest_settime;
        //For debug
        int expire_mode = ALARM_EXPIRE_MODE_NORMAL;
index f4240d0..13ec596 100644 (file)
@@ -48,10 +48,6 @@ int main(int argc, char** argv)
        GMainLoop *mainloop;
        int result;
 
-#if !(GLIB_CHECK_VERSION(2, 36, 0))
-       g_type_init();
-#endif
-
        mainloop = g_main_loop_new(NULL, FALSE);
        result = alarmmgr_init("org.tizen.alarmmgr.periodic");
 
index c66f788..16b4e52 100644 (file)
@@ -45,10 +45,6 @@ int main(int argc, char** argv)
        GMainLoop *mainloop;
        int result;
 
-#if !(GLIB_CHECK_VERSION(2, 36, 0))
-       g_type_init();
-#endif
-
        mainloop = g_main_loop_new(NULL, FALSE);
        result = alarmmgr_init("org.tizen.alarmmgr.refperiodic");