git: 24e13a49faab - main - Adjust sctp_drain() definition to avoid clang 15 warning
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 26 Jul 2022 18:00:24 UTC
The branch main has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=24e13a49faabb22ece97dc8e4718caf8f6bad84c commit 24e13a49faabb22ece97dc8e4718caf8f6bad84c Author: Dimitry Andric <dim@FreeBSD.org> AuthorDate: 2022-07-26 11:19:39 +0000 Commit: Dimitry Andric <dim@FreeBSD.org> CommitDate: 2022-07-26 17:59:55 +0000 Adjust sctp_drain() definition to avoid clang 15 warning With clang 15, the following -Werror warning is produced: sys/netinet/sctp_pcb.c:6946:11: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes] sctp_drain() ^ void This is because sctp_drain() is declared with a (void) argument list, but defined with an empty argument list. Make the definition match the declaration. MFC after: 3 days --- sys/netinet/sctp_pcb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netinet/sctp_pcb.c b/sys/netinet/sctp_pcb.c index bbbec5385c3c..73c550b86d65 100644 --- a/sys/netinet/sctp_pcb.c +++ b/sys/netinet/sctp_pcb.c @@ -6943,7 +6943,7 @@ sctp_drain_mbufs(struct sctp_tcb *stcb) } void -sctp_drain() +sctp_drain(void) { /* * We must walk the PCB lists for ALL associations here. The system