Update statistics only in case if delivery was successfull.
This commit is contained in:
parent
c55cd9092d
commit
f4b580b1dd
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=147104
@ -335,9 +335,11 @@ ngt_rcvdata(hook_p hook, item_p item)
|
||||
m2 = m_dup(m, M_DONTWAIT);
|
||||
if (m2) {
|
||||
/* Deliver duplicate */
|
||||
dup->stats.outOctets += m->m_pkthdr.len;
|
||||
dup->stats.outFrames++;
|
||||
NG_SEND_DATA_ONLY(error, dup->hook, m2);
|
||||
if (error == 0) {
|
||||
dup->stats.outOctets += m->m_pkthdr.len;
|
||||
dup->stats.outFrames++;
|
||||
}
|
||||
}
|
||||
}
|
||||
/* Deliver frame out destination hook */
|
||||
|
Loading…
Reference in New Issue
Block a user