From 6f2d816df4957c493da759ccbc06f07d337217fd Mon Sep 17 00:00:00 2001 From: Hallvard Furuseth Date: Sun, 1 Jul 2007 13:43:15 +0000 Subject: [PATCH] ITS#5035 - return ber_socket_t instead of ptrdiff_t from SLAP_EPOLL_EV_PTRFD(). Fixes a printf format bug. --- servers/slapd/daemon.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/servers/slapd/daemon.c b/servers/slapd/daemon.c index 8ce0ddb82d..499fc06c89 100644 --- a/servers/slapd/daemon.c +++ b/servers/slapd/daemon.c @@ -227,7 +227,8 @@ static struct slap_daemon { (int *)(ptr) <= &slap_daemon.sd_index[dtblsize]) ? 0 : 1 ) # define SLAP_EPOLL_EV_PTRFD(ptr) (SLAP_EPOLL_EV_LISTENER(ptr) ? \ - ((Listener *)ptr)->sl_sd : (int *)(ptr) - slap_daemon.sd_index) + ((Listener *)ptr)->sl_sd : \ + (ber_socket_t) ((int *)(ptr) - slap_daemon.sd_index)) # define SLAP_SOCK_DEL(s) do { \ int fd, rc, index = SLAP_EPOLL_SOCK_IX((s)); \ -- 2.39.5