mirror of
https://github.com/samba-team/samba.git
synced 2025-02-22 05:57:43 +03:00
messages_dgm_ref: Pass receiving "ev" to recv_cb
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
This commit is contained in:
parent
fc0b35b41c
commit
85c41375fd
@ -154,7 +154,8 @@ static struct messaging_rec *messaging_rec_create(
|
||||
return result;
|
||||
}
|
||||
|
||||
static void messaging_recv_cb(const uint8_t *msg, size_t msg_len,
|
||||
static void messaging_recv_cb(struct tevent_context *ev,
|
||||
const uint8_t *msg, size_t msg_len,
|
||||
int *fds, size_t num_fds,
|
||||
void *private_data)
|
||||
{
|
||||
|
@ -27,7 +27,8 @@
|
||||
struct msg_dgm_ref {
|
||||
struct msg_dgm_ref *prev, *next;
|
||||
void *tevent_handle;
|
||||
void (*recv_cb)(const uint8_t *msg, size_t msg_len,
|
||||
void (*recv_cb)(struct tevent_context *ev,
|
||||
const uint8_t *msg, size_t msg_len,
|
||||
int *fds, size_t num_fds, void *private_data);
|
||||
void *recv_cb_private_data;
|
||||
};
|
||||
@ -44,7 +45,8 @@ void *messaging_dgm_ref(TALLOC_CTX *mem_ctx, struct tevent_context *ev,
|
||||
uint64_t *unique,
|
||||
const char *socket_dir,
|
||||
const char *lockfile_dir,
|
||||
void (*recv_cb)(const uint8_t *msg, size_t msg_len,
|
||||
void (*recv_cb)(struct tevent_context *ev,
|
||||
const uint8_t *msg, size_t msg_len,
|
||||
int *fds, size_t num_fds,
|
||||
void *private_data),
|
||||
void *recv_cb_private_data,
|
||||
@ -127,7 +129,7 @@ static void msg_dgm_ref_recv(struct tevent_context *ev,
|
||||
*/
|
||||
for (r = refs; r != NULL; r = next) {
|
||||
next = r->next;
|
||||
r->recv_cb(msg, msg_len, fds, num_fds,
|
||||
r->recv_cb(ev, msg, msg_len, fds, num_fds,
|
||||
r->recv_cb_private_data);
|
||||
}
|
||||
}
|
||||
|
@ -28,7 +28,8 @@ void *messaging_dgm_ref(TALLOC_CTX *mem_ctx, struct tevent_context *ev,
|
||||
uint64_t *unique,
|
||||
const char *socket_dir,
|
||||
const char *lockfile_dir,
|
||||
void (*recv_cb)(const uint8_t *msg, size_t msg_len,
|
||||
void (*recv_cb)(struct tevent_context *ev,
|
||||
const uint8_t *msg, size_t msg_len,
|
||||
int *fds, size_t num_fds,
|
||||
void *private_data),
|
||||
void *recv_cb_private_data,
|
||||
|
@ -294,7 +294,8 @@ int imessaging_cleanup(struct imessaging_context *msg)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void imessaging_dgm_recv(const uint8_t *buf, size_t buf_len,
|
||||
static void imessaging_dgm_recv(struct tevent_context *ev,
|
||||
const uint8_t *buf, size_t buf_len,
|
||||
int *fds, size_t num_fds,
|
||||
void *private_data);
|
||||
|
||||
@ -415,7 +416,8 @@ fail:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static void imessaging_dgm_recv(const uint8_t *buf, size_t buf_len,
|
||||
static void imessaging_dgm_recv(struct tevent_context *ev,
|
||||
const uint8_t *buf, size_t buf_len,
|
||||
int *fds, size_t num_fds,
|
||||
void *private_data)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user