mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
Ensure that packet counts are always reset to 0 when
a route is cloned. Previously, they took on the count of their parent route (which was sometimes nonzero.) Submitted by: Andre Oppermann <oppermann@pipeline.ch> MFC after: 5 days
This commit is contained in:
parent
9917e01041
commit
54e84abb59
1 changed files with 1 additions and 0 deletions
|
|
@ -735,6 +735,7 @@ rtrequest1(req, info, ret_nrt)
|
|||
*/
|
||||
if (req == RTM_RESOLVE) {
|
||||
rt->rt_rmx = (*ret_nrt)->rt_rmx; /* copy metrics */
|
||||
rt->rt_rmx.rmx_pksent = 0; /* reset packet counter */
|
||||
if ((*ret_nrt)->rt_flags & (RTF_CLONING | RTF_PRCLONING)) {
|
||||
rt->rt_parent = (*ret_nrt);
|
||||
(*ret_nrt)->rt_refcnt++;
|
||||
|
|
|
|||
Loading…
Reference in a new issue