chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
bus: make sure sd_bus_get_timeout() returns a 0 timeout of there are already read...
[elogind.git]
/
src
/
libsystemd-bus
/
sd-event.c
diff --git
a/src/libsystemd-bus/sd-event.c
b/src/libsystemd-bus/sd-event.c
index dd8d3ee629214c7fb18d1c7a7a0b9e4fa5d254e8..ace97dc7393767f3fbdfa22a11cdba552b2557df 100644
(file)
--- a/
src/libsystemd-bus/sd-event.c
+++ b/
src/libsystemd-bus/sd-event.c
@@
-1748,7
+1748,7
@@
int sd_event_run(sd_event *e, uint64_t timeout) {
m = epoll_wait(e->epoll_fd, ev_queue, EPOLL_QUEUE_MAX,
timeout == (uint64_t) -1 ? -1 : (int) ((timeout + USEC_PER_MSEC - 1) / USEC_PER_MSEC));
if (m < 0) {
- r =
m
;
+ r =
errno == EAGAIN || errno == EINTR ? 0 : -errno
;
goto finish;
}