elm: Removed unnecessary null check for ecore_event_handler_del.
authorDaniel Juyung Seo <seojuyung2@gmail.com>
Wed, 22 Jan 2014 01:47:03 +0000 (10:47 +0900)
committerDaniel Juyung Seo <seojuyung2@gmail.com>
Wed, 22 Jan 2014 01:54:58 +0000 (10:54 +0900)
src/lib/elm_config.c
src/lib/elm_conform.c
src/lib/elm_icon.c
src/lib/elm_main.c

index 87e35e3..4cdc9b3 100644 (file)
@@ -2685,8 +2685,7 @@ _elm_config_shutdown(void)
 #undef ENGINE_COMPARE
      {
 #ifdef HAVE_ELEMENTARY_X
-        ecore_event_handler_del(_prop_change_handler);
-        _prop_change_handler = NULL;
+        ELM_SAFE_FREE(_prop_change_handler, ecore_event_handler_del);
 #endif
      }
    ELM_SAFE_FREE(_elm_config, _config_free);
index d487db0..65bd5f7 100644 (file)
@@ -924,7 +924,7 @@ _elm_conformant_smart_del(Eo *obj, void *_pd, va_list *list EINA_UNUSED)
    Elm_Conformant_Smart_Data *sd = _pd;
 
 #ifdef HAVE_ELEMENTARY_X
-   if (sd->prop_hdl) ecore_event_handler_del(sd->prop_hdl);
+   ecore_event_handler_del(sd->prop_hdl);
 #endif
 
    ecore_job_del(sd->show_region_job);
index 533de87..53663c5 100644 (file)
@@ -601,9 +601,7 @@ _elm_icon_smart_del(Eo *obj, void *_pd, va_list *list EINA_UNUSED)
    eina_stringshare_del(sd->thumb.file.key);
    eina_stringshare_del(sd->thumb.thumb.path);
    eina_stringshare_del(sd->thumb.thumb.key);
-
-   if (sd->thumb.eeh)
-     ecore_event_handler_del(sd->thumb.eeh);
+   ecore_event_handler_del(sd->thumb.eeh);
 
    _edje_signals_free(sd);
 
index c4da84f..81734e5 100644 (file)
@@ -326,10 +326,8 @@ elm_shutdown(void)
    _elm_init_count--;
    if (_elm_init_count > 0) return _elm_init_count;
 
-   if (system_handlers[0])
-     ecore_event_handler_del(system_handlers[0]);
-   if (system_handlers[1])
-     ecore_event_handler_del(system_handlers[1]);
+   ecore_event_handler_del(system_handlers[0]);
+   ecore_event_handler_del(system_handlers[1]);
 
    _elm_win_shutdown();
    while (_elm_win_deferred_free) ecore_main_loop_iterate();