aboutsummaryrefslogtreecommitdiffstats
path: root/src/vty
diff options
context:
space:
mode:
authorHarald Welte <laforge@osmocom.org>2022-11-03 11:05:58 +0100
committerHarald Welte <laforge@osmocom.org>2022-11-03 12:44:28 +0100
commite61d459cef11a599008e179b16d5b09cdd88bc95 (patch)
tree8d046c40e5ef3d37131cd2ec3408cb69b303e13d /src/vty
parent0d9b6b0e31f2d608c9ac18a861a905a94b978702 (diff)
Support building with -Werror=strict-prototypes / -Werror=old-style-definition
Unfortunately "-std=c99" is not sufficient to make gcc ignore code that uses constructs of earlier C standards, which were abandoned in C99. See https://lwn.net/ml/fedora-devel/Y1kvF35WozzGBpc8@redhat.com/ for some related discussion. Change-Id: I84fd99442d0cc400fa562fa33623c142649230e2
Diffstat (limited to 'src/vty')
-rw-r--r--src/vty/cpu_sched_vty.c2
-rw-r--r--src/vty/logging_vty.c2
-rw-r--r--src/vty/stats_vty.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/src/vty/cpu_sched_vty.c b/src/vty/cpu_sched_vty.c
index dbb3cd59..301e7a69 100644
--- a/src/vty/cpu_sched_vty.c
+++ b/src/vty/cpu_sched_vty.c
@@ -89,7 +89,7 @@ static struct cmd_node sched_node = {
};
/* returns number of configured CPUs in the system, or negative otherwise */
-static int get_num_cpus() {
+static int get_num_cpus(void) {
static unsigned int num_cpus = 0;
long ln;
diff --git a/src/vty/logging_vty.c b/src/vty/logging_vty.c
index c83dafdd..59c8a9cd 100644
--- a/src/vty/logging_vty.c
+++ b/src/vty/logging_vty.c
@@ -1196,7 +1196,7 @@ static void gen_vty_logp_cmd_strs(struct cmd_element *cmd)
/*! Register logging related commands to the VTY. Call this once from
* your application if you want to support those commands. */
-void logging_vty_add_cmds()
+void logging_vty_add_cmds(void)
{
install_lib_element_ve(&enable_logging_cmd);
install_lib_element_ve(&disable_logging_cmd);
diff --git a/src/vty/stats_vty.c b/src/vty/stats_vty.c
index e5acfa2c..299ec244 100644
--- a/src/vty/stats_vty.c
+++ b/src/vty/stats_vty.c
@@ -742,7 +742,7 @@ static int config_write_stats(struct vty *vty)
* Call this once during your application initialization if you would
* like to have stats VTY commands enabled.
*/
-void osmo_stats_vty_add_cmds()
+void osmo_stats_vty_add_cmds(void)
{
install_lib_element_ve(&show_stats_cmd);
install_lib_element_ve(&show_stats_level_cmd);