aboutsummaryrefslogtreecommitdiff
path: root/fdm.c
diff options
context:
space:
mode:
authorCraig Barnes <craigbarnes@protonmail.com>2021-02-10 09:01:51 +0000
committerCraig Barnes <craigbarnes@protonmail.com>2021-02-10 09:01:51 +0000
commit3c86af52c2a3e9352a88e969392575e55c3b6f74 (patch)
treedeed54e12bea0689caaad21f76f4f56b92e68d92 /fdm.c
parentConvert some more uses of xassert(false) to BUG("...") (diff)
Convert all but 2 remaining uses of xassert(false) to BUG("...")
Diffstat (limited to 'fdm.c')
-rw-r--r--fdm.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/fdm.c b/fdm.c
index ef956450..34d0fbff 100644
--- a/fdm.c
+++ b/fdm.c
@@ -105,16 +105,12 @@ fdm_add(struct fdm *fdm, int fd, int events, fdm_handler_t handler, void *data)
#if defined(_DEBUG)
int flags = fcntl(fd, F_GETFL);
if (!(flags & O_NONBLOCK)) {
- LOG_ERR("FD=%d is in blocking mode", fd);
- xassert(false);
- return false;
+ BUG("FD=%d is in blocking mode", fd);
}
tll_foreach(fdm->fds, it) {
if (it->item->fd == fd) {
- LOG_ERR("FD=%d already registered", fd);
- xassert(false);
- return false;
+ BUG("FD=%d already registered", fd);
}
}
#endif