winbind assertation failed (samba 3.0.32): both EVENT_FD_WRITE and
EVENT_FD_READ are set for event
Volodymyr Khomenko
Volodymyr.Khomenko at exanet.com
Fri Nov 21 13:26:48 GMT 2008
Hi all,
I've encountered pity issue with winbindd for samba 3.0.32:
it claimed about 'asseration failed' inside nsswitch/winbindd.c:rw_callback. Corrsponding code looks like this:
static void rw_callback(struct fd_event *event, int flags)
{
...
if (event->flags & EVENT_FD_WRITE) {
SMB_ASSERT(flags == EVENT_FD_WRITE);
...
}
if (event->flags & EVENT_FD_READ) {
SMB_ASSERT(flags == EVENT_FD_READ);
...
}
...
}
I've checked this by gdb and received:
#5 0x00da573b in rw_callback (event=0x9464f3c, flags=3) at nsswitch/winbindd.c:415
#6 0x00da6ae3 in process_loop () at nsswitch/winbindd.c:924
#7 0x00da7514 in main (argc=5, argv=0xbffc3414, envp=0xbffc342c) at nsswitch/winbindd.c:1195
I see that flags=3 (both EVENT_FD_WRITE=2 and EVENT_FD_READ=1 are set by process_loop):
ev = fd_events;
while (ev != NULL) {
...
int flags = 0;
if (FD_ISSET(ev->fd, &r_fds))
flags |= EVENT_FD_READ;
if (FD_ISSET(ev->fd, &w_fds))
flags |= EVENT_FD_WRITE;
if (flags)
ev->handler(ev, flags);
...
}
So what's wrong with such flags? Why do we suppose that only READ or WRITE flag has to be set?
Shouln'd we fix SMB_ASSERT statements to allow both flags?
Thanks for help,
Volodymyr Khomenko
Software Engineer - Core Technologies, Exanet Ltd.
More information about the samba-technical
mailing list