summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Adam <obnox@samba.org>2014-09-30 10:01:51 +0200
committerMichael Adam <obnox@samba.org>2014-09-30 16:36:10 +0200
commit797ada104e4a68f601e473c46dbb33871dda12e1 (patch)
tree7799679f381d8a3f0789cf7bc7e5053b08373b86
parentd7d9ec31dfe5d797307a7d107f0874260e7eab4a (diff)
downloadsamba-797ada104e4a68f601e473c46dbb33871dda12e1.tar.gz
s3:messaging: explain why the messaging_send*() functions need a tevent-loop.
Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org>
-rw-r--r--source3/include/messages.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/source3/include/messages.h b/source3/include/messages.h
index eb0943a95f1..fac561bcf69 100644
--- a/source3/include/messages.h
+++ b/source3/include/messages.h
@@ -105,6 +105,16 @@ NTSTATUS messaging_register(struct messaging_context *msg_ctx,
DATA_BLOB *data));
void messaging_deregister(struct messaging_context *ctx, uint32_t msg_type,
void *private_data);
+
+/**
+ * CAVEAT:
+ *
+ * While the messaging_send*() functions are synchronuous by API,
+ * they trigger a tevent-based loop upon sending bigger messages.
+ *
+ * Hence callers should not use these in purely synchonous code,
+ * but run a tevent_loop instead.
+ */
NTSTATUS messaging_send(struct messaging_context *msg_ctx,
struct server_id server,
uint32_t msg_type, const DATA_BLOB *data);