s3:ctdb_conn: add ctdbd_conn_get_fd() to get the fd out of the ctdb connection
authorMichael Adam <obnox@samba.org>
Fri, 22 Jan 2010 23:05:15 +0000 (00:05 +0100)
committerMichael Adam <obnox@samba.org>
Mon, 25 Jan 2010 14:08:41 +0000 (15:08 +0100)
Michael

source3/include/ctdbd_conn.h
source3/lib/ctdbd_conn.c

index 71516c73a6769101c64d812c69246828e7ffa960..c5ba5724cd46cad636e4d17c870dd93622a254d4 100644 (file)
@@ -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);
index a00c510efceca08c2c21ece7aa86dff5127c79a8..3983b3db1ca405dae29b9934220cddab68903bcb 100644 (file)
@@ -578,6 +578,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
  */