diff options
Diffstat (limited to 'src/rule.c')
-rw-r--r-- | src/rule.c | 15 |
1 files changed, 8 insertions, 7 deletions
@@ -1690,7 +1690,14 @@ static int do_command_monitor(struct netlink_ctx *ctx, struct cmd *cmd) { struct table *t; struct set *s; - struct netlink_mon_handler monhandler; + struct netlink_mon_handler monhandler = { + .monitor_flags = cmd->monitor->flags, + .format = cmd->monitor->format, + .ctx = ctx, + .loc = &cmd->location, + .cache = ctx->cache, + .debug_mask = ctx->debug_mask, + }; monhandler.cache_needed = need_cache(cmd); if (monhandler.cache_needed) { @@ -1725,12 +1732,6 @@ static int do_command_monitor(struct netlink_ctx *ctx, struct cmd *cmd) } } - monhandler.monitor_flags = cmd->monitor->flags; - monhandler.format = cmd->monitor->format; - monhandler.ctx = ctx; - monhandler.loc = &cmd->location; - monhandler.cache = ctx->cache; - return netlink_monitor(&monhandler, ctx->nf_sock); } |