diff options
Diffstat (limited to 'src/dispatch.c')
-rw-r--r-- | src/dispatch.c | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/src/dispatch.c b/src/dispatch.c index 728137b..89f69ea 100644 --- a/src/dispatch.c +++ b/src/dispatch.c @@ -192,6 +192,9 @@ dispatch_stream(struct plugin_state *state, int fd) slapi_log_error(SLAPI_LOG_PLUGIN, state->plugin_desc->spd_id, "failed to answer new stream request\n"); return; + } else { + slapi_log_error(SLAPI_LOG_PLUGIN, state->plugin_desc->spd_id, + "new stream client on %d\n", client); } /* Bundle up enough info for the thread to do its work. */ @@ -213,7 +216,8 @@ dispatch_stream(struct plugin_state *state, int fd) close(client); } slapi_log_error(SLAPI_LOG_PLUGIN, state->plugin_desc->spd_id, - "started client-specific thread\n"); + "started client-specific thread for client on %d\n", + client); return; } @@ -231,7 +235,7 @@ dispatch_dgram(struct plugin_state *state, int fd) reqsize = recvfrom(fd, dgram, sizeof(dgram), 0, (struct sockaddr *) &client_addr, &client_addrlen); slapi_log_error(SLAPI_LOG_PLUGIN, state->plugin_desc->spd_id, - "datagram request\n"); + "datagram request (%d bytes)\n", reqsize); /* Handle the request. */ nis_process_request(state, fd, @@ -254,11 +258,19 @@ dispatch_thread(void *p) fds[i].fd = state->listener[i].fd; fds[i].events = POLLIN; } + slapi_log_error(SLAPI_LOG_PLUGIN, state->plugin_desc->spd_id, + "listening for next request\n"); switch (poll(fds, state->n_listeners, -1)) { case -1: + slapi_log_error(SLAPI_LOG_PLUGIN, + state->plugin_desc->spd_id, + "done waiting\n"); return NULL; break; case 0: + slapi_log_error(SLAPI_LOG_PLUGIN, + state->plugin_desc->spd_id, + "no request(?)\n"); continue; default: /* Iterate over listening sockets which have work for |