summaryrefslogtreecommitdiff
path: root/legacy
diff options
context:
space:
mode:
Diffstat (limited to 'legacy')
-rw-r--r--legacy/ecore/src/lib/ecore/ecore.c6
-rw-r--r--legacy/edje/src/lib/edje_main.c5
-rw-r--r--legacy/eet/src/lib/eet_lib.c5
-rw-r--r--legacy/eeze/src/lib/eeze_main.c5
-rw-r--r--legacy/efreet/src/lib/efreet.c5
-rw-r--r--legacy/eina/src/lib/eina_main.c5
-rw-r--r--legacy/eio/src/lib/eio_main.c5
-rw-r--r--legacy/embryo/src/lib/embryo_main.c6
-rw-r--r--legacy/emotion/src/lib/emotion_main.c5
-rw-r--r--legacy/ethumb/src/lib/ethumb.c5
-rw-r--r--legacy/evas/src/lib/canvas/evas_main.c5
11 files changed, 57 insertions, 0 deletions
diff --git a/legacy/ecore/src/lib/ecore/ecore.c b/legacy/ecore/src/lib/ecore/ecore.c
index 7fbe943022..5dfe3d6fa0 100644
--- a/legacy/ecore/src/lib/ecore/ecore.c
+++ b/legacy/ecore/src/lib/ecore/ecore.c
@@ -228,6 +228,12 @@ ecore_shutdown(void)
228 * take a lock here because _ecore_event_shutdown() does callbacks 228 * take a lock here because _ecore_event_shutdown() does callbacks
229 */ 229 */
230 _ecore_lock(); 230 _ecore_lock();
231 if (_ecore_init_count <= 0)
232 {
233 ERR("Init count not greater than 0 in shutdown.");
234 _ecore_unlock();
235 return 0;
236 }
231 if (--_ecore_init_count != 0) 237 if (--_ecore_init_count != 0)
232 goto unlock; 238 goto unlock;
233 239
diff --git a/legacy/edje/src/lib/edje_main.c b/legacy/edje/src/lib/edje_main.c
index 846daf5087..98b4647a39 100644
--- a/legacy/edje/src/lib/edje_main.c
+++ b/legacy/edje/src/lib/edje_main.c
@@ -170,6 +170,11 @@ _edje_lib_unref(void)
170EAPI int 170EAPI int
171edje_shutdown(void) 171edje_shutdown(void)
172{ 172{
173 if (_edje_init_count <= 0)
174 {
175 ERR("Init count not greater than 0 in shutdown.");
176 return 0;
177 }
173 if (--_edje_init_count != 0) 178 if (--_edje_init_count != 0)
174 return _edje_init_count; 179 return _edje_init_count;
175 180
diff --git a/legacy/eet/src/lib/eet_lib.c b/legacy/eet/src/lib/eet_lib.c
index a350d11f3c..bef99b30c0 100644
--- a/legacy/eet/src/lib/eet_lib.c
+++ b/legacy/eet/src/lib/eet_lib.c
@@ -633,6 +633,11 @@ shutdown_eina:
633EAPI int 633EAPI int
634eet_shutdown(void) 634eet_shutdown(void)
635{ 635{
636 if (eet_init_count <= 0)
637 {
638 ERR("Init count not greater than 0 in shutdown.");
639 return 0;
640 }
636 if (--eet_init_count != 0) 641 if (--eet_init_count != 0)
637 return eet_init_count; 642 return eet_init_count;
638 643
diff --git a/legacy/eeze/src/lib/eeze_main.c b/legacy/eeze/src/lib/eeze_main.c
index e1fe7f0842..b9954cfd31 100644
--- a/legacy/eeze/src/lib/eeze_main.c
+++ b/legacy/eeze/src/lib/eeze_main.c
@@ -82,6 +82,11 @@ eina_fail:
82EAPI int 82EAPI int
83eeze_shutdown(void) 83eeze_shutdown(void)
84{ 84{
85 if (_eeze_init_count <= 0)
86 {
87 EINA_LOG_ERR("Init count not greater than 0 in shutdown.");
88 return 0;
89 }
85 if (--_eeze_init_count != 0) 90 if (--_eeze_init_count != 0)
86 return _eeze_init_count; 91 return _eeze_init_count;
87 92
diff --git a/legacy/efreet/src/lib/efreet.c b/legacy/efreet/src/lib/efreet.c
index dde421cd78..42a49d548c 100644
--- a/legacy/efreet/src/lib/efreet.c
+++ b/legacy/efreet/src/lib/efreet.c
@@ -136,6 +136,11 @@ shutdown_eina:
136EAPI int 136EAPI int
137efreet_shutdown(void) 137efreet_shutdown(void)
138{ 138{
139 if (_efreet_init_count <= 0)
140 {
141 ERR("Init count not greater than 0 in shutdown.");
142 return 0;
143 }
139 if (--_efreet_init_count != 0) 144 if (--_efreet_init_count != 0)
140 return _efreet_init_count; 145 return _efreet_init_count;
141 146
diff --git a/legacy/eina/src/lib/eina_main.c b/legacy/eina/src/lib/eina_main.c
index 5cf77e726d..2dc9b303ab 100644
--- a/legacy/eina/src/lib/eina_main.c
+++ b/legacy/eina/src/lib/eina_main.c
@@ -307,6 +307,11 @@ eina_init(void)
307EAPI int 307EAPI int
308eina_shutdown(void) 308eina_shutdown(void)
309{ 309{
310 if (_eina_main_count <= 0)
311 {
312 ERR("Init count not greater than 0 in shutdown.");
313 return 0;
314 }
310 _eina_main_count--; 315 _eina_main_count--;
311 if (EINA_UNLIKELY(_eina_main_count == 0)) 316 if (EINA_UNLIKELY(_eina_main_count == 0))
312 { 317 {
diff --git a/legacy/eio/src/lib/eio_main.c b/legacy/eio/src/lib/eio_main.c
index 37ed701969..47ea55bb63 100644
--- a/legacy/eio/src/lib/eio_main.c
+++ b/legacy/eio/src/lib/eio_main.c
@@ -236,6 +236,11 @@ eio_shutdown(void)
236 Eio_Progress *pg; 236 Eio_Progress *pg;
237 Eio_File_Associate *asso; 237 Eio_File_Associate *asso;
238 238
239 if (_eio_count <= 0)
240 {
241 EINA_LOG_ERR("Init count not greater than 0 in shutdown.");
242 return 0;
243 }
239 _eio_count--; 244 _eio_count--;
240 245
241 if (_eio_count > 0) return _eio_count; 246 if (_eio_count > 0) return _eio_count;
diff --git a/legacy/embryo/src/lib/embryo_main.c b/legacy/embryo/src/lib/embryo_main.c
index 0b01b11141..3c57ec7c37 100644
--- a/legacy/embryo/src/lib/embryo_main.c
+++ b/legacy/embryo/src/lib/embryo_main.c
@@ -2,6 +2,7 @@
2# include "config.h" 2# include "config.h"
3#endif 3#endif
4 4
5#include <stdio.h>
5#include <stdlib.h> 6#include <stdlib.h>
6#include <time.h> 7#include <time.h>
7 8
@@ -29,6 +30,11 @@ embryo_init(void)
29EAPI int 30EAPI int
30embryo_shutdown(void) 31embryo_shutdown(void)
31{ 32{
33 if (_embryo_init_count <= 0)
34 {
35 printf("%s:%i Init count not greater than 0 in shutdown.", __FUNCTION__, __LINE__);
36 return 0;
37 }
32 if (--_embryo_init_count != 0) 38 if (--_embryo_init_count != 0)
33 return _embryo_init_count; 39 return _embryo_init_count;
34 40
diff --git a/legacy/emotion/src/lib/emotion_main.c b/legacy/emotion/src/lib/emotion_main.c
index a5e9694b80..74c6eebbd4 100644
--- a/legacy/emotion/src/lib/emotion_main.c
+++ b/legacy/emotion/src/lib/emotion_main.c
@@ -383,6 +383,11 @@ emotion_shutdown(void)
383{ 383{
384 Emotion_Webcam *ew; 384 Emotion_Webcam *ew;
385 385
386 if (_emotion_webcams_count <= 0)
387 {
388 EINA_LOG_ERR("Init count not greater than 0 in shutdown.");
389 return EINA_FALSE;
390 }
386 if (--_emotion_webcams_count) return EINA_TRUE; 391 if (--_emotion_webcams_count) return EINA_TRUE;
387 392
388 EINA_LIST_FREE(_emotion_webcams->webcams, ew) 393 EINA_LIST_FREE(_emotion_webcams->webcams, ew)
diff --git a/legacy/ethumb/src/lib/ethumb.c b/legacy/ethumb/src/lib/ethumb.c
index 07ac716ac7..973f5e657c 100644
--- a/legacy/ethumb/src/lib/ethumb.c
+++ b/legacy/ethumb/src/lib/ethumb.c
@@ -202,6 +202,11 @@ ethumb_init(void)
202EAPI int 202EAPI int
203ethumb_shutdown(void) 203ethumb_shutdown(void)
204{ 204{
205 if (initcount <= 0)
206 {
207 EINA_LOG_ERR("Init count not greater than 0 in shutdown.");
208 return 0;
209 }
205 initcount--; 210 initcount--;
206 if (initcount == 0) 211 if (initcount == 0)
207 { 212 {
diff --git a/legacy/evas/src/lib/canvas/evas_main.c b/legacy/evas/src/lib/canvas/evas_main.c
index b02405d08d..271ccd7d9c 100644
--- a/legacy/evas/src/lib/canvas/evas_main.c
+++ b/legacy/evas/src/lib/canvas/evas_main.c
@@ -77,6 +77,11 @@ evas_init(void)
77EAPI int 77EAPI int
78evas_shutdown(void) 78evas_shutdown(void)
79{ 79{
80 if (_evas_init_count <= 0)
81 {
82 EINA_LOG_ERR("Init count not greater than 0 in shutdown.");
83 return 0;
84 }
80 if (--_evas_init_count != 0) 85 if (--_evas_init_count != 0)
81 return _evas_init_count; 86 return _evas_init_count;
82 87