git: c434383146a2 - stable/13 - listen(2): fix wrong MFC
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 30 May 2023 09:29:52 UTC
The branch stable/13 has been updated by eugen: URL: https://cgit.FreeBSD.org/src/commit/?id=c434383146a264c396d8bcaafd40507f7bf46e56 commit c434383146a264c396d8bcaafd40507f7bf46e56 Author: Eugene Grosbein <eugen@FreeBSD.org> AuthorDate: 2023-05-30 09:27:25 +0000 Commit: Eugene Grosbein <eugen@FreeBSD.org> CommitDate: 2023-05-30 09:27:25 +0000 listen(2): fix wrong MFC Direct commit: fix wrong conflict resolution in previous MFC: listen(2): improve administrator control over logging Fixes: 773c91ccc8922c047d3632ae5849cd824992c313 --- sys/kern/uipc_socket.c | 33 ++++++--------------------------- 1 file changed, 6 insertions(+), 27 deletions(-) diff --git a/sys/kern/uipc_socket.c b/sys/kern/uipc_socket.c index 32ad819be81b..669bddcd629b 100644 --- a/sys/kern/uipc_socket.c +++ b/sys/kern/uipc_socket.c @@ -699,33 +699,12 @@ sonewconn(struct socket *head, int connstatus) } KASSERT(sbuf_len(&descrsb) > 0, ("%s: sbuf creation failed", __func__)); - /* - * Preserve the historic listen queue overflow log - * message, that starts with "sonewconn:". It has - * been known to sysadmins for years and also test - * sys/kern/sonewconn_overflow checks for it. - */ - if (head->so_cred == 0) { - log(LOG_PRI(sooverprio), - "sonewconn: pcb %p (%s): " - "Listen queue overflow: %i already in " - "queue awaiting acceptance (%d " - "occurrences)\n", head->so_pcb, - sbuf_data(&descrsb), - qlen, overcount); - } else { - log(LOG_PRI(sooverprio), - "sonewconn: pcb %p (%s): " - "Listen queue overflow: " - "%i already in queue awaiting acceptance " - "(%d occurrences), euid %d, rgid %d, jail %s\n", - head->so_pcb, sbuf_data(&descrsb), qlen, - overcount, head->so_cred->cr_uid, - head->so_cred->cr_rgid, - head->so_cred->cr_prison ? - head->so_cred->cr_prison->pr_name : - "not_jailed"); - } + log(LOG_PRI(sooverprio), + "%s: pcb %p (%s): Listen queue overflow: " + "%i already in queue awaiting acceptance " + "(%d occurrences)\n", + __func__, head->so_pcb, sbuf_data(&descrsb), + qlen, overcount); sbuf_delete(&descrsb); overcount = 0;