mirror of
https://salsa.debian.org/ha-team/libqb
synced 2026-08-18 18:40:42 +00:00
IPC: only modify the dispatch if we get EAGAIN
Signed-off-by: Angus Salkeld <asalkeld@redhat.com>
This commit is contained in:
parent
a4411105a7
commit
78374c2ed3
15
lib/ipcs.c
15
lib/ipcs.c
@ -325,15 +325,14 @@ new_event_notification(struct qb_ipcs_connection * c)
|
||||
c->outstanding_notifiers++;
|
||||
} else {
|
||||
res = qb_ipc_us_send(&c->setup, &c->outstanding_notifiers, 1);
|
||||
if (res == 1) {
|
||||
return res;
|
||||
if (res == -EAGAIN) {
|
||||
/*
|
||||
* notify the client later, when we can.
|
||||
*/
|
||||
c->outstanding_notifiers++;
|
||||
c->poll_events = POLLOUT | POLLIN | POLLPRI | POLLNVAL;
|
||||
(void)_modify_dispatch_descriptor_(c);
|
||||
}
|
||||
/*
|
||||
* notify the client later, when we can.
|
||||
*/
|
||||
c->outstanding_notifiers++;
|
||||
c->poll_events = POLLOUT | POLLIN | POLLPRI | POLLNVAL;
|
||||
(void)_modify_dispatch_descriptor_(c);
|
||||
}
|
||||
return res;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user