summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2011-09-20 04:47:21 +0200
committerStefan Metzmacher <metze@samba.org>2011-10-24 08:25:31 +0200
commit8f356baab6c46535a1ed8a5e53859d2e69ce3166 (patch)
treee6ff1cf3161a66b6cdc58e16adc8258d5bfadfbe
parent99666e4a8dd2751b1d39f370e82caa912f7079a2 (diff)
downloadsamba-8f356baab6c46535a1ed8a5e53859d2e69ce3166.tar.gz
samba-8f356baab6c46535a1ed8a5e53859d2e69ce3166.tar.bz2
samba-8f356baab6c46535a1ed8a5e53859d2e69ce3166.zip
s3:libsmb: remove unused sync read_smb()
metze
-rw-r--r--source3/libsmb/read_smb.c24
-rw-r--r--source3/libsmb/read_smb.h1
2 files changed, 0 insertions, 25 deletions
diff --git a/source3/libsmb/read_smb.c b/source3/libsmb/read_smb.c
index ecedcfbe9d..48cdd2faa8 100644
--- a/source3/libsmb/read_smb.c
+++ b/source3/libsmb/read_smb.c
@@ -108,27 +108,3 @@ ssize_t read_smb_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx,
*pbuf = talloc_move(mem_ctx, &state->buf);
return talloc_get_size(*pbuf);
}
-
-ssize_t read_smb(int fd, TALLOC_CTX *mem_ctx, uint8_t **pbuf, int *perrno)
-{
- TALLOC_CTX *frame = talloc_stackframe();
- struct event_context *ev;
- struct tevent_req *req;
- ssize_t ret = -1;
-
- ev = event_context_init(frame);
- if (ev == NULL) {
- goto fail;
- }
- req = read_smb_send(frame, ev, fd);
- if (req == NULL) {
- goto fail;
- }
- if (!tevent_req_poll(req, ev)) {
- goto fail;
- }
- ret = read_smb_recv(req, mem_ctx, pbuf, perrno);
- fail:
- TALLOC_FREE(frame);
- return ret;
-}
diff --git a/source3/libsmb/read_smb.h b/source3/libsmb/read_smb.h
index b0846c1ec3..ae4dfdd63a 100644
--- a/source3/libsmb/read_smb.h
+++ b/source3/libsmb/read_smb.h
@@ -29,6 +29,5 @@ struct tevent_req *read_smb_send(TALLOC_CTX *mem_ctx,
ssize_t read_smb_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx,
uint8_t **pbuf, int *perrno);
-ssize_t read_smb(int fd, TALLOC_CTX *mem_ctx, uint8_t **pbuf, int *perrno);
#endif