[Openvpn-devel,v1] add missing (void) to win32 function declarations

Message ID 20250205170232.3473-1-gert@greenie.muc.de
State Accepted
Headers show
Series [Openvpn-devel,v1] add missing (void) to win32 function declarations | expand

Commit Message

Gert Doering Feb. 5, 2025, 5:02 p.m. UTC
mingw complains about "old-style function definition" and since we
use explicit (void) everyhwere else...

Change-Id: I59e34058d6e0611208767fbcf39d1b91784ebcf9
Signed-off-by: Gert Doering <gert@greenie.muc.de>
Acked-by: Frank Lichtenheld <frank@lichtenheld.com>
---

This change was reviewed on Gerrit and approved by at least one
developer. I request to merge it to master.

Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/886
This mail reflects revision 1 of this Change.

Acked-by according to Gerrit (reflected above):
Frank Lichtenheld <frank@lichtenheld.com>

Comments

Gert Doering Feb. 5, 2025, 5:10 p.m. UTC | #1
Found these while testing #815 on ubuntu/mingw...

Patch has been applied to the master branch.

commit 817577d56ba48e160d4c7ad939ce62a93b55ab7f
Author: Gert Doering
Date:   Wed Feb 5 18:02:32 2025 +0100

     add missing (void) to win32 function declarations

     Signed-off-by: Gert Doering <gert@greenie.muc.de>
     Acked-by: Frank Lichtenheld <frank@lichtenheld.com>
     Message-Id: <20250205170232.3473-1-gert@greenie.muc.de>
     URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg30813.html
     Signed-off-by: Gert Doering <gert@greenie.muc.de>


--
kind regards,

Gert Doering

Patch

diff --git a/src/openvpn/dco_win.c b/src/openvpn/dco_win.c
index 46b2d03..62d7109 100644
--- a/src/openvpn/dco_win.c
+++ b/src/openvpn/dco_win.c
@@ -502,7 +502,7 @@ 
 }
 
 const char *
-dco_get_supported_ciphers()
+dco_get_supported_ciphers(void)
 {
     /*
      * this API can be called either from user mode or kernel mode,
diff --git a/src/openvpn/error.c b/src/openvpn/error.c
index ec65d5e..d5bb802 100644
--- a/src/openvpn/error.c
+++ b/src/openvpn/error.c
@@ -505,7 +505,7 @@ 
 static int orig_stderr;
 
 int
-get_orig_stderr()
+get_orig_stderr(void)
 {
     return orig_stderr ? orig_stderr : _fileno(stderr);
 }