diff options
Diffstat (limited to 'lib/netfilter')
-rw-r--r-- | lib/netfilter/ct.c | 7 | ||||
-rw-r--r-- | lib/netfilter/exp.c | 7 | ||||
-rw-r--r-- | lib/netfilter/nfnl.c | 3 |
3 files changed, 16 insertions, 1 deletions
diff --git a/lib/netfilter/ct.c b/lib/netfilter/ct.c index 903c584e..d589790e 100644 --- a/lib/netfilter/ct.c +++ b/lib/netfilter/ct.c @@ -413,6 +413,13 @@ static int ct_msg_parser(struct nl_cache_ops *ops, struct sockaddr_nl *who, return err; } +/** + * Send nfnl ct dump request + * @arg sk Netlink socket. + * + * @return 0 on success or a negative error code. Due to a bug, this function + * returns the number of bytes sent. Treat any non-negative number as success. + */ int nfnl_ct_dump_request(struct nl_sock *sk) { return nfnl_send_simple(sk, NFNL_SUBSYS_CTNETLINK, IPCTNL_MSG_CT_GET, diff --git a/lib/netfilter/exp.c b/lib/netfilter/exp.c index 9cfdd2bf..650127c8 100644 --- a/lib/netfilter/exp.c +++ b/lib/netfilter/exp.c @@ -305,6 +305,13 @@ static int exp_msg_parser(struct nl_cache_ops *ops, struct sockaddr_nl *who, return err; } +/** + * Send nfnl exp dump request + * @arg sk Netlink socket. + * + * @return 0 on success or a negative error code. Due to a bug, this function + * returns the number of bytes sent. Treat any non-negative number as success. + */ int nfnl_exp_dump_request(struct nl_sock *sk) { return nfnl_send_simple(sk, NFNL_SUBSYS_CTNETLINK_EXP, IPCTNL_MSG_EXP_GET, diff --git a/lib/netfilter/nfnl.c b/lib/netfilter/nfnl.c index f028a859..9b524470 100644 --- a/lib/netfilter/nfnl.c +++ b/lib/netfilter/nfnl.c @@ -102,7 +102,8 @@ int nfnl_connect(struct nl_sock *sk) * @arg family nfnetlink address family * @arg res_id nfnetlink resource id * - * @return Newly allocated netlink message or NULL. + * @return 0 on success or a negative error code. Due to a bug, this function + * returns the number of bytes sent. Treat any non-negative number as success. */ int nfnl_send_simple(struct nl_sock *sk, uint8_t subsys_id, uint8_t type, int flags, uint8_t family, uint16_t res_id) |