mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2025-05-11 20:28:13 +00:00
BUG/MEDIUM: lua: wakeup task on bad conditions
the condition was : * wakeup for read if the output channel contains data * wakeup for write if the input channel have some room.
This commit is contained in:
parent
5a50a85f4f
commit
eba6f64a5f
@ -1582,11 +1582,11 @@ static void hlua_socket_handler(struct appctx *appctx)
|
|||||||
appctx->ctx.hlua.connected = 1;
|
appctx->ctx.hlua.connected = 1;
|
||||||
|
|
||||||
/* Wake the tasks which wants to write if the buffer have avalaible space. */
|
/* Wake the tasks which wants to write if the buffer have avalaible space. */
|
||||||
if (channel_may_recv(si_oc(si)))
|
if (channel_may_recv(si_ic(si)))
|
||||||
hlua_com_wake(&appctx->ctx.hlua.wake_on_write);
|
hlua_com_wake(&appctx->ctx.hlua.wake_on_write);
|
||||||
|
|
||||||
/* Wake the tasks which wants to read if the buffer contains data. */
|
/* Wake the tasks which wants to read if the buffer contains data. */
|
||||||
if (channel_is_empty(si_ic(si)))
|
if (!channel_is_empty(si_oc(si)))
|
||||||
hlua_com_wake(&appctx->ctx.hlua.wake_on_read);
|
hlua_com_wake(&appctx->ctx.hlua.wake_on_read);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user