summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Adam <obnox@samba.org>2010-01-23 00:05:15 +0100
committerMichael Adam <obnox@samba.org>2010-02-12 23:12:12 +0100
commite4af0bc5af2c3ee025ca7fac251c3672ba2c8dd5 (patch)
tree94d1da2ca88ee61e272504d443427e7ee690e954
parent8e306b51b79d3dacd68be9f13aa8455e2eb4c03f (diff)
downloadsamba-e4af0bc5af2c3ee025ca7fac251c3672ba2c8dd5.tar.gz
samba-e4af0bc5af2c3ee025ca7fac251c3672ba2c8dd5.tar.bz2
samba-e4af0bc5af2c3ee025ca7fac251c3672ba2c8dd5.zip
s3:ctdb_conn: add ctdbd_conn_get_fd() to get the fd out of the ctdb connection
Michael
-rw-r--r--source3/include/ctdbd_conn.h2
-rw-r--r--source3/lib/ctdbd_conn.c5
2 files changed, 7 insertions, 0 deletions
diff --git a/source3/include/ctdbd_conn.h b/source3/include/ctdbd_conn.h
index 71516c73a6..c5ba5724cd 100644
--- a/source3/include/ctdbd_conn.h
+++ b/source3/include/ctdbd_conn.h
@@ -33,6 +33,8 @@ NTSTATUS ctdbd_register_msg_ctx(struct ctdbd_connection *conn,
struct messaging_context *msg_ctx);
struct messaging_context *ctdb_conn_msg_ctx(struct ctdbd_connection *conn);
+int ctdbd_conn_get_fd(struct ctdbd_connection *conn);
+
NTSTATUS ctdbd_messaging_send(struct ctdbd_connection *conn,
uint32 dst_vnn, uint64 dst_srvid,
struct messaging_rec *msg);
diff --git a/source3/lib/ctdbd_conn.c b/source3/lib/ctdbd_conn.c
index 743594d43b..6b50009e00 100644
--- a/source3/lib/ctdbd_conn.c
+++ b/source3/lib/ctdbd_conn.c
@@ -519,6 +519,11 @@ struct messaging_context *ctdb_conn_msg_ctx(struct ctdbd_connection *conn)
return conn->msg_ctx;
}
+int ctdbd_conn_get_fd(struct ctdbd_connection *conn)
+{
+ return packet_get_fd(conn->pkt);
+}
+
/*
* Packet handler to receive and handle a ctdb message
*/