git: 049bc90cdbcb - stable/12 - Adjust sctp_drain() definition to avoid clang 15 warning
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 29 Jul 2022 18:48:26 UTC
The branch stable/12 has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=049bc90cdbcbe6970c5d47c0c23c33c61bf11cab commit 049bc90cdbcbe6970c5d47c0c23c33c61bf11cab Author: Dimitry Andric <dim@FreeBSD.org> AuthorDate: 2022-07-26 11:19:39 +0000 Commit: Dimitry Andric <dim@FreeBSD.org> CommitDate: 2022-07-29 18:35:37 +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 (cherry picked from commit 24e13a49faabb22ece97dc8e4718caf8f6bad84c) --- 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 227b6cae49bc..a1e6ebb8589b 100644 --- a/sys/netinet/sctp_pcb.c +++ b/sys/netinet/sctp_pcb.c @@ -7032,7 +7032,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