mirror of
https://gitee.com/acl-dev/acl.git
synced 2024-11-29 18:37:41 +08:00
Fixed one problem in event.c
This commit is contained in:
parent
3d86688e3c
commit
bd3e8fb8a7
@ -912,7 +912,7 @@ GENERATE_HTML = NO
|
|||||||
# If a relative path is entered the value of OUTPUT_DIRECTORY will be
|
# If a relative path is entered the value of OUTPUT_DIRECTORY will be
|
||||||
# put in front of it. If left blank `html' will be used as the default path.
|
# put in front of it. If left blank `html' will be used as the default path.
|
||||||
|
|
||||||
HTML_OUTPUT = html
|
#HTML_OUTPUT = html
|
||||||
|
|
||||||
# The HTML_FILE_EXTENSION tag can be used to specify the file extension for
|
# The HTML_FILE_EXTENSION tag can be used to specify the file extension for
|
||||||
# each generated HTML page (for example: .htm,.php,.asp). If it is left blank
|
# each generated HTML page (for example: .htm,.php,.asp). If it is left blank
|
||||||
|
@ -142,20 +142,20 @@ void event_fire(ACL_EVENT *ev)
|
|||||||
|
|
||||||
if (r_timeout > 0 && r_callback) {
|
if (r_timeout > 0 && r_callback) {
|
||||||
fdp->r_ttl = ev->present + fdp->r_timeout;
|
fdp->r_ttl = ev->present + fdp->r_timeout;
|
||||||
fdp->r_callback(ACL_EVENT_RW_TIMEOUT, ev,
|
r_callback(ACL_EVENT_RW_TIMEOUT, ev,
|
||||||
fdp->stream, fdp->r_context);
|
fdp->stream, fdp->r_context);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ready[i] maybe been set NULL in r_callback */
|
/* ready[i] maybe been set NULL in r_callback */
|
||||||
if (w_timeout > 0 && w_callback && ready[i]) {
|
if (w_timeout > 0 && w_callback && ready[i]) {
|
||||||
fdp->w_ttl = ev->present + fdp->w_timeout;
|
fdp->w_ttl = ev->present + fdp->w_timeout;
|
||||||
fdp->w_callback(ACL_EVENT_RW_TIMEOUT, ev,
|
w_callback(ACL_EVENT_RW_TIMEOUT, ev,
|
||||||
fdp->stream, fdp->w_context);
|
fdp->stream, fdp->w_context);
|
||||||
}
|
}
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((type & (ACL_EVENT_READ | ACL_EVENT_ACCEPT))) {
|
if ((type & (ACL_EVENT_READ | ACL_EVENT_ACCEPT)) && fdp->r_callback) {
|
||||||
fdp->event_type &= ~(ACL_EVENT_READ | ACL_EVENT_ACCEPT);
|
fdp->event_type &= ~(ACL_EVENT_READ | ACL_EVENT_ACCEPT);
|
||||||
if (fdp->r_timeout > 0)
|
if (fdp->r_timeout > 0)
|
||||||
fdp->r_ttl = ev->present + fdp->r_timeout;
|
fdp->r_ttl = ev->present + fdp->r_timeout;
|
||||||
@ -178,7 +178,7 @@ void event_fire(ACL_EVENT *ev)
|
|||||||
if (ready[i] == NULL)
|
if (ready[i] == NULL)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if ((type & (ACL_EVENT_WRITE | ACL_EVENT_CONNECT))) {
|
if ((type & (ACL_EVENT_WRITE | ACL_EVENT_CONNECT)) && fdp->w_callback) {
|
||||||
if (fdp->w_timeout > 0)
|
if (fdp->w_timeout > 0)
|
||||||
fdp->w_ttl = ev->present + fdp->w_timeout;
|
fdp->w_ttl = ev->present + fdp->w_timeout;
|
||||||
fdp->event_type &= ~(ACL_EVENT_WRITE | ACL_EVENT_CONNECT);
|
fdp->event_type &= ~(ACL_EVENT_WRITE | ACL_EVENT_CONNECT);
|
||||||
|
Loading…
Reference in New Issue
Block a user