Subtle fix to the accept filter LRU code. In some cases, a newly
initialized socket with no qlimit was being passed in. In order to handle this case properly, we must not use >= when comparing queue sizes to qlimit. As a result of this improper handling, a panic could result in certain cases. PR: 38325 MFC after: 3 days
This commit is contained in:
parent
9a1cd8e5a2
commit
184fec1a09
@ -231,7 +231,7 @@ sonewconn(head, connstatus)
|
||||
SOCK_UNLOCK(so);
|
||||
head->so_qlen++;
|
||||
} else {
|
||||
if (head->so_incqlen >= head->so_qlimit) {
|
||||
if (head->so_incqlen > head->so_qlimit) {
|
||||
struct socket *sp;
|
||||
sp = TAILQ_FIRST(&head->so_incomp);
|
||||
(void) soabort(sp);
|
||||
|
@ -231,7 +231,7 @@ sonewconn(head, connstatus)
|
||||
SOCK_UNLOCK(so);
|
||||
head->so_qlen++;
|
||||
} else {
|
||||
if (head->so_incqlen >= head->so_qlimit) {
|
||||
if (head->so_incqlen > head->so_qlimit) {
|
||||
struct socket *sp;
|
||||
sp = TAILQ_FIRST(&head->so_incomp);
|
||||
(void) soabort(sp);
|
||||
|
Loading…
x
Reference in New Issue
Block a user