X-Git-Url: https://git.llucax.com/software/libev.git/blobdiff_plain/7e305734bf37cb00b5be4f32a80bccdf83c768b8..d89bdc728203c12cec56cf6e5284882842f19ca4:/ev.c?ds=inline diff --git a/ev.c b/ev.c index ce8987f..2c34141 100644 --- a/ev.c +++ b/ev.c @@ -748,7 +748,7 @@ enable_secure (void) #endif } -int +unsigned int ev_method (EV_P) { return method; @@ -772,7 +772,7 @@ loop_init (EV_P_ unsigned int flags) now_floor = mn_now; rtmn_diff = ev_rt_now - mn_now; - if (!(flags & EVMETHOD_NOENV) && !enable_secure () && getenv ("LIBEV_FLAGS")) + if (!(flags & EVFLAG_NOENV) && !enable_secure () && getenv ("LIBEV_FLAGS")) flags = atoi (getenv ("LIBEV_FLAGS")); if (!(flags & 0x0000ffff)) @@ -895,7 +895,7 @@ struct ev_loop * #else int #endif -ev_default_loop (unsigned int methods) +ev_default_loop (unsigned int flags) { if (sigpipe [0] == sigpipe [1]) if (pipe (sigpipe)) @@ -909,7 +909,7 @@ ev_default_loop (unsigned int methods) default_loop = 1; #endif - loop_init (EV_A_ methods); + loop_init (EV_A_ flags); if (ev_method (EV_A)) { @@ -1384,7 +1384,10 @@ ev_timer_again (EV_P_ struct ev_timer *w) ev_timer_stop (EV_A_ w); } else if (w->repeat) - ev_timer_start (EV_A_ w); + { + w->at = w->repeat; + ev_timer_start (EV_A_ w); + } } #if EV_PERIODICS