diff options
| -rw-r--r-- | net/netfilter/nf_conntrack_netlink.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/net/netfilter/nf_conntrack_netlink.c b/net/netfilter/nf_conntrack_netlink.c index 77d209c235a0..636617ccfe25 100644 --- a/net/netfilter/nf_conntrack_netlink.c +++ b/net/netfilter/nf_conntrack_netlink.c | |||
| @@ -1015,6 +1015,17 @@ ctnetlink_get_conntrack(struct sock *ctnl, struct sk_buff *skb, | |||
| 1015 | if (err < 0) | 1015 | if (err < 0) |
| 1016 | goto out; | 1016 | goto out; |
| 1017 | 1017 | ||
| 1018 | if (NFNL_MSG_TYPE(nlh->nlmsg_type) == IPCTNL_MSG_CT_GET_CTRZERO) { | ||
| 1019 | struct nf_conn_counter *acct; | ||
| 1020 | |||
| 1021 | acct = nf_conn_acct_find(ct); | ||
| 1022 | if (acct) { | ||
| 1023 | atomic64_set(&acct[IP_CT_DIR_ORIGINAL].bytes, 0); | ||
| 1024 | atomic64_set(&acct[IP_CT_DIR_ORIGINAL].packets, 0); | ||
| 1025 | atomic64_set(&acct[IP_CT_DIR_REPLY].bytes, 0); | ||
| 1026 | atomic64_set(&acct[IP_CT_DIR_REPLY].packets, 0); | ||
| 1027 | } | ||
| 1028 | } | ||
| 1018 | return 0; | 1029 | return 0; |
| 1019 | 1030 | ||
| 1020 | free: | 1031 | free: |
