From 09d1b2324cf02c20daa005e6f5d55dc107303af7 Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Tue, 10 Mar 2009 13:54:57 +0100 Subject: tevent: add tevent_req_received() function This function can be called as last action of a _recv() function, it destroys the data attached to the tevent_req. metze --- lib/tevent/tevent.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'lib/tevent/tevent.h') diff --git a/lib/tevent/tevent.h b/lib/tevent/tevent.h index 5089d18ec2..8ae9eaf545 100644 --- a/lib/tevent/tevent.h +++ b/lib/tevent/tevent.h @@ -165,7 +165,11 @@ enum tevent_req_state { /** * No memory in between */ - TEVENT_REQ_NO_MEMORY + TEVENT_REQ_NO_MEMORY, + /** + * the request is already received by the caller + */ + TEVENT_REQ_RECEIVED }; /** @@ -238,6 +242,8 @@ bool tevent_req_is_error(struct tevent_req *req, enum tevent_req_state *state, uint64_t *error); +void tevent_req_received(struct tevent_req *req); + struct tevent_req *tevent_wakeup_send(TALLOC_CTX *mem_ctx, struct tevent_context *ev, struct timeval wakeup_time); -- cgit