aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPau Espin Pedrol <pespin@sysmocom.de>2019-08-05 14:30:44 +0200
committerPau Espin Pedrol <pespin@sysmocom.de>2019-08-05 14:30:47 +0200
commitcd2ac56bd4f6cb783c2f826686a0809d7d2327f3 (patch)
tree3e2d32f1222d942944fbbbde2c9c55d3883a9d5b
parent2c076bcb4dc1bc2ada340441c2f898c55318209f (diff)
Remove undefined param passed to {logging,osmo_stats}_vty_add_cmds
Since March 15th 2017, libosmocore API logging_vty_add_cmds() had its parameter removed (c65c5b4ea075ef6cef11fff9442ae0b15c1d6af7). However, definition in C file doesn't contain "(void)", which means number of parameters is undefined and thus compiler doesn't complain. Let's remove parameters from all callers before enforcing "(void)" on it. API osmo_stats_vty_add_cmds never had a param list but has seem problem (no "void"), so some users decided to pass a parameter to it. Related: OS#4138 Change-Id: Ic1ac815eafab49577ff883a5d700ecca5936d216
-rw-r--r--src/pcu_main.cpp2
-rw-r--r--src/pcu_vty.c6
-rw-r--r--src/pcu_vty.h2
-rw-r--r--tests/edge/EdgeTest.cpp2
-rw-r--r--tests/emu/pcu_emu.cpp2
-rw-r--r--tests/llc/LlcTest.cpp2
-rw-r--r--tests/ms/MsTest.cpp2
-rw-r--r--tests/tbf/TbfTest.cpp2
8 files changed, 10 insertions, 10 deletions
diff --git a/src/pcu_main.cpp b/src/pcu_main.cpp
index fa075cd..21cb244 100644
--- a/src/pcu_main.cpp
+++ b/src/pcu_main.cpp
@@ -277,7 +277,7 @@ int main(int argc, char *argv[])
bssgp_set_log_ss(DBSSGP);
vty_init(&pcu_vty_info);
- pcu_vty_init(&gprs_log_info);
+ pcu_vty_init();
handle_options(argc, argv);
if ((!!spoof_mcc) + (!!spoof_mnc) == 1) {
diff --git a/src/pcu_vty.c b/src/pcu_vty.c
index 3a733ef..1e4f50c 100644
--- a/src/pcu_vty.c
+++ b/src/pcu_vty.c
@@ -1147,7 +1147,7 @@ struct vty_app_info pcu_vty_info = {
.is_config_node = pcu_vty_is_config_node,
};
-int pcu_vty_init(const struct log_info *cat)
+int pcu_vty_init(void)
{
// install_element_ve(&show_pcu_cmd);
@@ -1164,8 +1164,8 @@ int pcu_vty_init(const struct log_info *cat)
NO_STR "GSMTAP Category\n",
"\n", "", 0);
- logging_vty_add_cmds(cat);
- osmo_stats_vty_add_cmds(cat);
+ logging_vty_add_cmds();
+ osmo_stats_vty_add_cmds();
install_node(&pcu_node, config_write_pcu);
install_element(CONFIG_NODE, &cfg_pcu_cmd);
diff --git a/src/pcu_vty.h b/src/pcu_vty.h
index a075350..2097561 100644
--- a/src/pcu_vty.h
+++ b/src/pcu_vty.h
@@ -12,7 +12,7 @@ enum pcu_vty_node {
int pcu_vty_go_parent(struct vty *vty);
int pcu_vty_is_config_node(struct vty *vty, int node);
-int pcu_vty_init(const struct log_info *cat);
+int pcu_vty_init();
extern struct vty_app_info pcu_vty_info;
diff --git a/tests/edge/EdgeTest.cpp b/tests/edge/EdgeTest.cpp
index f124b76..3f424d1 100644
--- a/tests/edge/EdgeTest.cpp
+++ b/tests/edge/EdgeTest.cpp
@@ -1411,7 +1411,7 @@ int main(int argc, char **argv)
log_set_print_filename(osmo_stderr_target, 0);
vty_init(&pcu_vty_info);
- pcu_vty_init(&gprs_log_info);
+ pcu_vty_init();
test_coding_scheme();
test_rlc_info_init();
diff --git a/tests/emu/pcu_emu.cpp b/tests/emu/pcu_emu.cpp
index e0190bf..7ecabe1 100644
--- a/tests/emu/pcu_emu.cpp
+++ b/tests/emu/pcu_emu.cpp
@@ -121,7 +121,7 @@ int main(int argc, char **argv)
}
vty_init(&pcu_vty_info);
- pcu_vty_init(&gprs_log_info);
+ pcu_vty_init();
current_test = 0;
diff --git a/tests/llc/LlcTest.cpp b/tests/llc/LlcTest.cpp
index 13bda3c..8163f34 100644
--- a/tests/llc/LlcTest.cpp
+++ b/tests/llc/LlcTest.cpp
@@ -229,7 +229,7 @@ int main(int argc, char **argv)
log_parse_category_mask(osmo_stderr_target, "DPCU,3:DLGLOBAL,1:");
vty_init(&pcu_vty_info);
- pcu_vty_init(&gprs_log_info);
+ pcu_vty_init();
test_llc_queue();
test_llc_meta();
diff --git a/tests/ms/MsTest.cpp b/tests/ms/MsTest.cpp
index 4f8f3a0..c74b3a6 100644
--- a/tests/ms/MsTest.cpp
+++ b/tests/ms/MsTest.cpp
@@ -616,7 +616,7 @@ int main(int argc, char **argv)
log_parse_category_mask(osmo_stderr_target, "DPCU,3:DRLCMAC,3");
vty_init(&pcu_vty_info);
- pcu_vty_init(&gprs_log_info);
+ pcu_vty_init();
test_ms_state();
test_ms_callback();
diff --git a/tests/tbf/TbfTest.cpp b/tests/tbf/TbfTest.cpp
index 675cf89..8d1b344 100644
--- a/tests/tbf/TbfTest.cpp
+++ b/tests/tbf/TbfTest.cpp
@@ -3290,7 +3290,7 @@ int main(int argc, char **argv)
"DL1IF,6:DTBF,1:DTBFUL,1:DTBFDL,1:DLGLOBAL,2:");
vty_init(&pcu_vty_info);
- pcu_vty_init(&gprs_log_info);
+ pcu_vty_init();
test_tbf_base();
test_tbf_tlli_update();