This is an automated email from the ASF dual-hosted git repository.
scw00 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/trafficserver.git
The following commit(s) were added to refs/heads/master by this push:
new 96e0aca correct negative event's timeout_at value
96e0aca is described below
commit 96e0aca148a2776ce2b095732733987c2e6a86ce
Author: scw00 <[email protected]>
AuthorDate: Mon Feb 5 15:52:53 2018 +0800
correct negative event's timeout_at value
---
iocore/eventsystem/P_UnixEThread.h | 12 ++++++++++--
1 file changed, 10 insertions(+), 2 deletions(-)
diff --git a/iocore/eventsystem/P_UnixEThread.h
b/iocore/eventsystem/P_UnixEThread.h
index e0135a6..1303ded 100644
--- a/iocore/eventsystem/P_UnixEThread.h
+++ b/iocore/eventsystem/P_UnixEThread.h
@@ -78,7 +78,11 @@ EThread::schedule_every(Continuation *cont, ink_hrtime t,
int callback_event, vo
Event *e = ::eventAllocator.alloc();
e->callback_event = callback_event;
e->cookie = cookie;
- return schedule(e->init(cont, get_hrtime() + t, t));
+ if (t < 0) {
+ return schedule(e->init(cont, t, t));
+ } else {
+ return schedule(e->init(cont, get_hrtime() + t, t));
+ }
}
TS_INLINE Event *
@@ -128,7 +132,11 @@ EThread::schedule_every_local(Continuation *cont,
ink_hrtime t, int callback_eve
Event *e = EVENT_ALLOC(eventAllocator, this);
e->callback_event = callback_event;
e->cookie = cookie;
- return schedule_local(e->init(cont, get_hrtime() + t, t));
+ if (t < 0) {
+ return schedule(e->init(cont, t, t));
+ } else {
+ return schedule(e->init(cont, get_hrtime() + t, t));
+ }
}
TS_INLINE Event *
--
To stop receiving notification emails like this one, please contact
[email protected].