diff options
author | Volker Lendecke <vl@samba.org> | 2009-05-22 22:30:09 +0200 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2009-05-24 13:50:43 +0200 |
commit | 4906d7fc679210555871bcb080e504fcc11734c6 (patch) | |
tree | 170da497fee5fe7c09644c12ad43b0844c6ab6d7 /source3/lib/wb_reqtrans.c | |
parent | e337124c555aee32f0d075b8008c77da3065c1e1 (diff) | |
download | samba-4906d7fc679210555871bcb080e504fcc11734c6.tar.gz samba-4906d7fc679210555871bcb080e504fcc11734c6.tar.bz2 samba-4906d7fc679210555871bcb080e504fcc11734c6.zip |
Do queueing in wbclient.c
The _trigger fn must know about wbc_context, while we were waiting in the
queue the fd might have changed
Diffstat (limited to 'source3/lib/wb_reqtrans.c')
-rw-r--r-- | source3/lib/wb_reqtrans.c | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/source3/lib/wb_reqtrans.c b/source3/lib/wb_reqtrans.c index 038e5bda17..55883ba8c7 100644 --- a/source3/lib/wb_reqtrans.c +++ b/source3/lib/wb_reqtrans.c @@ -338,30 +338,6 @@ ssize_t wb_resp_write_recv(struct tevent_req *req, int *err) return state->ret; } -static bool closed_fd(int fd) -{ - struct timeval tv; - fd_set r_fds; - int selret; - - if (fd == -1) { - return true; - } - - FD_ZERO(&r_fds); - FD_SET(fd, &r_fds); - ZERO_STRUCT(tv); - - selret = select(fd+1, &r_fds, NULL, NULL, &tv); - if (selret == -1) { - return true; - } - if (selret == 0) { - return false; - } - return (FD_ISSET(fd, &r_fds)); -} - struct wb_simple_trans_state { struct tevent_context *ev; int fd; @@ -384,11 +360,6 @@ struct tevent_req *wb_simple_trans_send(TALLOC_CTX *mem_ctx, return NULL; } - if (closed_fd(fd)) { - tevent_req_error(req, EPIPE); - return tevent_req_post(req, ev); - } - wb_req->length = sizeof(struct winbindd_request); state->ev = ev; |