Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 23 Jul 2022 08:58:18 GMT
From:      Dimitry Andric <dim@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: 08c55de237ed - stable/13 - Adjust db_flush_line() definition to avoid clang 15 warning
Message-ID:  <202207230858.26N8wI73012632@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch stable/13 has been updated by dim:

URL: https://cgit.FreeBSD.org/src/commit/?id=08c55de237ed0067781981ef4704480938186104

commit 08c55de237ed0067781981ef4704480938186104
Author:     Dimitry Andric <dim@FreeBSD.org>
AuthorDate: 2022-07-19 18:31:08 +0000
Commit:     Dimitry Andric <dim@FreeBSD.org>
CommitDate: 2022-07-23 08:56:44 +0000

    Adjust db_flush_line() definition to avoid clang 15 warning
    
    With clang 15, the following -Werror warnings is produced:
    
        sys/ddb/db_lex.c:94:14: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
        db_flush_line()
                     ^
                      void
    
    This is because db_flush_line() 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 939cb349b2ca4d3fcdc72ab1258eadee5e54881c)
---
 sys/ddb/db_lex.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sys/ddb/db_lex.c b/sys/ddb/db_lex.c
index 457790ee8605..093afa2238b6 100644
--- a/sys/ddb/db_lex.c
+++ b/sys/ddb/db_lex.c
@@ -91,7 +91,7 @@ db_get_line(void)
 }
 
 static void
-db_flush_line()
+db_flush_line(void)
 {
 	db_lp = db_line;
 	db_endlp = db_line;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202207230858.26N8wI73012632>