#48035 slapd_daemon should call ns_thrpool_wait instead of while(!g_get_shutdown())
Closed: Fixed None Opened 5 years ago by rmeggins.

    while(!g_get_shutdown())
    {
#ifdef ENABLE_NUNC_STANS
        DS_Sleep(1);
#else

This should just be a call to ns_thrpool_wait like this:

    if (ns_thrpool_wait(tp)) {
            /* error */
        }
        /* start other cleanup here */

{{{
listener_info listener_idxs = NULL; / array of indexes of listener sockets in the ct->fd array */
}}}
make this static instead of global

Move the static int listeners = 0; / number of listener sockets / to be next to static listener_info *listener_idxs = NULL

{{{
ns_job_done(listener_idxs[i].ns_job);
}}}
set listener_idxs[i].ns_job = NULL to make sure no one else tries to reference the job.

Replying to [comment:3 rmeggins]:

{{{
listener_info listener_idxs = NULL; / array of indexes of listener sockets in the ct->fd array */
}}}
make this static instead of global

Move the static int listeners = 0; / number of listener sockets / to be next to static listener_info *listener_idxs = NULL

{{{
ns_job_done(listener_idxs[i].ns_job);
}}}
set listener_idxs[i].ns_job = NULL to make sure no one else tries to reference the job.

New patch attached...

commit aabcb76e68aa5e8af1883d33ad2266a8d0046dc8

Metadata Update from @mreynolds:
- Issue assigned to mreynolds
- Issue set to the milestone: 1.3.4 backlog

3 years ago

Login to comment on this ticket.

Metadata