summaryrefslogtreecommitdiff
path: root/legacy
diff options
context:
space:
mode:
authorMike Blumenkrantz <michael.blumenkrantz@gmail.com>2011-01-01 03:07:58 +0000
committerMike Blumenkrantz <michael.blumenkrantz@gmail.com>2011-01-01 03:07:58 +0000
commit677b5d0c73ce76f7cdbf2a7f222d7395d0f58712 (patch)
treedb0222e77c34c2427393c1277967f527f4149d6a /legacy
parentc730fdf95ebc3ace0f7c0d68ff3a6e84257d84bb (diff)
this adds a small helper function for use in finding cases where the epoll fd gets deleted and calls it after each fdh function
if epoll support is not enabled, the function does nothing this will be removed prior to actual release, but will be very useful in finding the last epoll bugs until then SVN revision: 55791
Diffstat (limited to 'legacy')
-rw-r--r--legacy/ecore/src/lib/ecore/ecore_main.c13
-rw-r--r--legacy/ecore/src/lib/ecore/ecore_private.h1
2 files changed, 14 insertions, 0 deletions
diff --git a/legacy/ecore/src/lib/ecore/ecore_main.c b/legacy/ecore/src/lib/ecore/ecore_main.c
index 6f7bf7e938..5fa9b2f0f2 100644
--- a/legacy/ecore/src/lib/ecore/ecore_main.c
+++ b/legacy/ecore/src/lib/ecore/ecore_main.c
@@ -154,6 +154,18 @@ static gboolean ecore_idling;
154static gboolean ecore_fds_ready; 154static gboolean ecore_fds_ready;
155#endif 155#endif
156 156
157void
158_ecore_fd_valid(void)
159{
160#ifdef HAVE_EPOLL
161 if (fcntl(epoll_fd, F_GETFD) < 0)
162 {
163 ERR("arghhh you caught me! report a backtrace to edevel!");
164 sleep(5);
165 }
166#endif
167}
168
157#ifdef HAVE_EPOLL 169#ifdef HAVE_EPOLL
158static inline int 170static inline int
159_ecore_get_epoll_fd(void) 171_ecore_get_epoll_fd(void)
@@ -1307,6 +1319,7 @@ _ecore_main_fd_handlers_call(void)
1307 1319
1308 } 1320 }
1309 fdh->references--; 1321 fdh->references--;
1322 _ecore_fd_valid();
1310 1323
1311 fdh->read_active = EINA_FALSE; 1324 fdh->read_active = EINA_FALSE;
1312 fdh->write_active = EINA_FALSE; 1325 fdh->write_active = EINA_FALSE;
diff --git a/legacy/ecore/src/lib/ecore/ecore_private.h b/legacy/ecore/src/lib/ecore/ecore_private.h
index 00ab9203f9..7e2afa0872 100644
--- a/legacy/ecore/src/lib/ecore/ecore_private.h
+++ b/legacy/ecore/src/lib/ecore/ecore_private.h
@@ -118,6 +118,7 @@ typedef unsigned int Ecore_Magic;
118EAPI void _ecore_magic_fail(const void *d, Ecore_Magic m, Ecore_Magic req_m, const char *fname); 118EAPI void _ecore_magic_fail(const void *d, Ecore_Magic m, Ecore_Magic req_m, const char *fname);
119 119
120void _ecore_time_init(void); 120void _ecore_time_init(void);
121void _ecore_fd_valid(void);
121 122
122void _ecore_timer_shutdown(void); 123void _ecore_timer_shutdown(void);
123void _ecore_timer_cleanup(void); 124void _ecore_timer_cleanup(void);