]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
nft: Make add_log() static
authorPhil Sutter <phil@nwl.cc>
Sat, 5 Oct 2024 12:13:44 +0000 (14:13 +0200)
committerPhil Sutter <phil@nwl.cc>
Thu, 10 Apr 2025 16:45:42 +0000 (18:45 +0200)
It is not used outside of nft.c, though in the wrong position so keep
the declaration but right above its caller.

Signed-off-by: Phil Sutter <phil@nwl.cc>
iptables/nft.c
iptables/nft.h

index 21a7e211d7d780de5485d43e3bfe5b3a79f39771..d1e04d2b1deb0f7d937bf896d5916022f8c34144 100644 (file)
@@ -1595,6 +1595,8 @@ int add_verdict(struct nftnl_rule *r, int verdict)
        return 0;
 }
 
+static int add_log(struct nftnl_rule *r, struct iptables_command_state *cs);
+
 int add_action(struct nftnl_rule *r, struct iptables_command_state *cs,
               bool goto_set)
 {
@@ -1623,7 +1625,7 @@ int add_action(struct nftnl_rule *r, struct iptables_command_state *cs,
        return ret;
 }
 
-int add_log(struct nftnl_rule *r, struct iptables_command_state *cs)
+static int add_log(struct nftnl_rule *r, struct iptables_command_state *cs)
 {
        struct nftnl_expr *expr;
        struct xt_nflog_info *info = (struct xt_nflog_info *)cs->target->t->data;
index 8f17f3100a19083c86054f77ed69c150f47acf78..09b4341f92f8eda8dcab85c37225de6c1a32b10f 100644 (file)
@@ -197,7 +197,6 @@ int add_match(struct nft_handle *h, struct nft_rule_ctx *ctx,
 int add_target(struct nftnl_rule *r, struct xt_entry_target *t);
 int add_jumpto(struct nftnl_rule *r, const char *name, int verdict);
 int add_action(struct nftnl_rule *r, struct iptables_command_state *cs, bool goto_set);
-int add_log(struct nftnl_rule *r, struct iptables_command_state *cs);
 char *get_comment(const void *data, uint32_t data_len);
 
 enum nft_rule_print {