From baee4163beb5b05cdef09a3ab134c992f8d47129 Mon Sep 17 00:00:00 2001 From: "Alfred E. Heggestad" Date: Mon, 25 Mar 2013 21:53:48 +0000 Subject: [PATCH] bfcp: added bfcp_sock() accessor function, so we can use medianat in application --- include/re_bfcp.h | 1 + src/bfcp/conn.c | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/include/re_bfcp.h b/include/re_bfcp.h index 549eb8c..d30ea30 100644 --- a/include/re_bfcp.h +++ b/include/re_bfcp.h @@ -260,6 +260,7 @@ const char *bfcp_prim_name(enum bfcp_prim prim); /* conn */ int bfcp_listen(struct bfcp_conn **bcp, enum bfcp_transp tp, struct sa *laddr, bfcp_recv_h *recvh, void *arg); +void *bfcp_sock(const struct bfcp_conn *bc); /* request */ diff --git a/src/bfcp/conn.c b/src/bfcp/conn.c index 9875e2c..df175d9 100644 --- a/src/bfcp/conn.c +++ b/src/bfcp/conn.c @@ -146,3 +146,9 @@ int bfcp_send(struct bfcp_conn *bc, const struct sa *dst, struct mbuf *mb) return ENOSYS; } } + + +void *bfcp_sock(const struct bfcp_conn *bc) +{ + return bc ? bc->us : NULL; +}