Use INSERT_OBJECT_INT_LINK_INDEX macro instead of TAILQ_INSERT_TAIL when
filling the table of ALTQ queues retrieved from the kernel. It is possible for the kernel to return the queues not by pa.altq.qid order. When this happens, pf_snmp would only partially fill its table. PR: bin/120974 Submitted by: Mykola Dzham <i -at- levsha.org.ua> MFC after: 3 days
This commit is contained in:
parent
16151645c2
commit
0fecb888b2
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=179476
@ -1025,7 +1025,7 @@ pfq_refresh(void)
|
||||
memcpy(&e->altq, &pa.altq, sizeof(struct pf_altq));
|
||||
e->index = pa.altq.qid;
|
||||
pfq_table_count = i;
|
||||
TAILQ_INSERT_TAIL(&pfq_table, e, link);
|
||||
INSERT_OBJECT_INT_LINK_INDEX(e, &pfq_table, link, index);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user