extern int netlink_delete_rule(struct netlink_ctx *ctx, const struct handle *h,
const struct location *loc);
extern int netlink_add_rule_list(struct netlink_ctx *ctx, const struct handle *h,
- struct list_head *rule_list);
+ const struct list_head *rule_list);
extern int netlink_add_rule_batch(struct netlink_ctx *ctx,
const struct handle *h,
const struct rule *rule, uint32_t flags);
extern int netlink_get_setelems(struct netlink_ctx *ctx, const struct handle *h,
const struct location *loc, struct set *set);
-extern void netlink_dump_table(struct nftnl_table *nlt);
-extern void netlink_dump_chain(struct nftnl_chain *nlc);
-extern void netlink_dump_rule(struct nftnl_rule *nlr);
-extern void netlink_dump_expr(struct nftnl_expr *nle);
-extern void netlink_dump_set(struct nftnl_set *nls);
+extern void netlink_dump_table(const struct nftnl_table *nlt);
+extern void netlink_dump_chain(const struct nftnl_chain *nlc);
+extern void netlink_dump_rule(const struct nftnl_rule *nlr);
+extern void netlink_dump_expr(const struct nftnl_expr *nle);
+extern void netlink_dump_set(const struct nftnl_set *nls);
extern int netlink_batch_send(struct list_head *err_list);
}
int netlink_add_rule_list(struct netlink_ctx *ctx, const struct handle *h,
- struct list_head *rule_list)
+ const struct list_head *rule_list)
{
struct rule *rule;
return err;
}
-void netlink_dump_rule(struct nftnl_rule *nlr)
+void netlink_dump_rule(const struct nftnl_rule *nlr)
{
#ifdef DEBUG
char buf[4096];
#endif
}
-void netlink_dump_expr(struct nftnl_expr *nle)
+void netlink_dump_expr(const struct nftnl_expr *nle)
{
#ifdef DEBUG
char buf[4096];
return netlink_del_rule_batch(ctx, h, loc);
}
-void netlink_dump_chain(struct nftnl_chain *nlc)
+void netlink_dump_chain(const struct nftnl_chain *nlc)
{
#ifdef DEBUG
char buf[4096];
}
static struct chain *netlink_delinearize_chain(struct netlink_ctx *ctx,
- struct nftnl_chain *nlc)
+ const struct nftnl_chain *nlc)
{
struct chain *chain;
return netlink_del_table_compat(ctx, h, loc);
}
-void netlink_dump_table(struct nftnl_table *nlt)
+void netlink_dump_table(const struct nftnl_table *nlt)
{
#ifdef DEBUG
char buf[4096];
}
static struct table *netlink_delinearize_table(struct netlink_ctx *ctx,
- struct nftnl_table *nlt)
+ const struct nftnl_table *nlt)
{
struct table *table;
}
}
-void netlink_dump_set(struct nftnl_set *nls)
+void netlink_dump_set(const struct nftnl_set *nls)
{
#ifdef DEBUG
char buf[4096];
}
static struct set *netlink_delinearize_set(struct netlink_ctx *ctx,
- struct nftnl_set *nls)
+ const struct nftnl_set *nls)
{
struct set *set;
const struct datatype *keytype, *datatype;
}
static int netlink_delinearize_setelem(struct nftnl_set_elem *nlse,
- struct set *set)
+ const struct set *set)
{
struct nft_data_delinearize nld;
struct expr *expr, *key, *data;