diff options
author | Harald Welte <laforge@osmocom.org> | 2022-11-03 11:05:58 +0100 |
---|---|---|
committer | Harald Welte <laforge@osmocom.org> | 2022-11-03 12:44:28 +0100 |
commit | e61d459cef11a599008e179b16d5b09cdd88bc95 (patch) | |
tree | 8d046c40e5ef3d37131cd2ec3408cb69b303e13d | |
parent | 0d9b6b0e31f2d608c9ac18a861a905a94b978702 (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
55 files changed, 214 insertions, 214 deletions
diff --git a/include/osmocom/core/counter.h b/include/osmocom/core/counter.h index 0d56bc4a..7b677cb1 100644 --- a/include/osmocom/core/counter.h +++ b/include/osmocom/core/counter.h @@ -52,7 +52,7 @@ void osmo_counter_free(struct osmo_counter *ctr) int osmo_counters_for_each(int (*handle_counter)(struct osmo_counter *, void *), void *data); -int osmo_counters_count(); +int osmo_counters_count(void); struct osmo_counter *osmo_counter_get_by_name(const char *name); diff --git a/include/osmocom/core/select.h b/include/osmocom/core/select.h index e9f19a56..fc148512 100644 --- a/include/osmocom/core/select.h +++ b/include/osmocom/core/select.h @@ -105,8 +105,8 @@ struct osmo_signalfd { struct osmo_signalfd * osmo_signalfd_setup(void *ctx, sigset_t set, osmo_signalfd_cb *cb, void *data); -void osmo_select_shutdown_request(); -int osmo_select_shutdown_requested(); -bool osmo_select_shutdown_done(); +void osmo_select_shutdown_request(void); +int osmo_select_shutdown_requested(void); +bool osmo_select_shutdown_done(void); /*! @} */ diff --git a/include/osmocom/gprs/gprs_bssgp.h b/include/osmocom/gprs/gprs_bssgp.h index 09f640dc..6c043327 100644 --- a/include/osmocom/gprs/gprs_bssgp.h +++ b/include/osmocom/gprs/gprs_bssgp.h @@ -235,7 +235,7 @@ int bssgp_fc_in(struct bssgp_flow_control *fc, struct msgb *msg, int bssgp_fc_ms_init(struct bssgp_flow_control *fc_ms, uint16_t bvci, uint16_t nsei, uint32_t max_queue_depth); -void bssgp_flush_all_queues(); +void bssgp_flush_all_queues(void); void bssgp_fc_flush_queue(struct bssgp_flow_control *fc); /* gprs_bssgp_vty.c */ diff --git a/include/osmocom/gsm/gsm0808.h b/include/osmocom/gsm/gsm0808.h index b4c78032..dcff4159 100644 --- a/include/osmocom/gsm/gsm0808.h +++ b/include/osmocom/gsm/gsm0808.h @@ -73,7 +73,7 @@ struct msgb *gsm0808_create_cipher2(const struct gsm0808_cipher_mode_command *cm struct msgb *gsm0808_create_cipher_complete(struct msgb *layer3, uint8_t alg_id); struct msgb *gsm0808_create_cipher_reject(enum gsm0808_cause cause); struct msgb *gsm0808_create_cipher_reject_ext(enum gsm0808_cause_class class, uint8_t ext); -struct msgb *gsm0808_create_classmark_request(); +struct msgb *gsm0808_create_classmark_request(void); struct msgb *gsm0808_create_classmark_update(const uint8_t *cm2, uint8_t cm2_len, const uint8_t *cm3, uint8_t cm3_len); struct msgb *gsm0808_create_sapi_reject_cause(uint8_t link_id, uint16_t cause); @@ -269,8 +269,8 @@ struct gsm0808_handover_command { }; struct msgb *gsm0808_create_handover_command(const struct gsm0808_handover_command *params); -struct msgb *gsm0808_create_handover_detect(); -struct msgb *gsm0808_create_handover_succeeded(); +struct msgb *gsm0808_create_handover_detect(void); +struct msgb *gsm0808_create_handover_succeeded(void); struct gsm0808_handover_complete { bool rr_cause_present; diff --git a/include/osmocom/vty/command.h b/include/osmocom/vty/command.h index e3919fb8..61b58815 100644 --- a/include/osmocom/vty/command.h +++ b/include/osmocom/vty/command.h @@ -442,8 +442,8 @@ char *argv_concat(const char **argv, int argc, int shift); vector cmd_make_strvec(const char *); int cmd_make_strvec2(const char *string, char **indent, vector *strvec_p); void cmd_free_strvec(vector); -vector cmd_describe_command(); -char **cmd_complete_command(); +vector cmd_describe_command(vector vline, struct vty *vty, int *status); +char **cmd_complete_command(vector vline, struct vty *vty, int *status); const char *cmd_prompt(enum node_type); int config_from_file(struct vty *, FILE *); enum node_type node_parent(enum node_type); diff --git a/include/osmocom/vty/logging.h b/include/osmocom/vty/logging.h index 90c8fa17..0ea64321 100644 --- a/include/osmocom/vty/logging.h +++ b/include/osmocom/vty/logging.h @@ -6,7 +6,7 @@ #define FILTER_STR "Filter log messages\n" struct log_info; -void logging_vty_add_cmds(); +void logging_vty_add_cmds(void); void logging_vty_add_deprecated_subsys(void *ctx, const char *name); struct vty; struct log_target *osmo_log_vty2tgt(struct vty *vty); diff --git a/src/counter.c b/src/counter.c index cbee7b9e..dace15f3 100644 --- a/src/counter.c +++ b/src/counter.c @@ -75,7 +75,7 @@ int osmo_counters_for_each(int (*handle_counter)(struct osmo_counter *, void *), /*! Counts the registered counter * \returns amount of counters */ -int osmo_counters_count() +int osmo_counters_count(void) { return llist_count(&counters); } diff --git a/src/gb/gprs_bssgp.c b/src/gb/gprs_bssgp.c index c967f730..7abef804 100644 --- a/src/gb/gprs_bssgp.c +++ b/src/gb/gprs_bssgp.c @@ -1428,7 +1428,7 @@ void bssgp_fc_flush_queue(struct bssgp_flow_control *fc) /*! * \brief Flush the queues of all BSSGP contexts. */ -void bssgp_flush_all_queues() +void bssgp_flush_all_queues(void) { struct bssgp_bvc_ctx *bctx; diff --git a/src/gsm/gsm0808.c b/src/gsm/gsm0808.c index e0578327..89a8874d 100644 --- a/src/gsm/gsm0808.c +++ b/src/gsm/gsm0808.c @@ -418,7 +418,7 @@ struct msgb *gsm0808_create_lcls_notification(enum gsm0808_lcls_status status, b /*! Create BSSMAP Classmark Request message * \returns callee-allocated msgb with BSSMAP Classmark Request message */ -struct msgb *gsm0808_create_classmark_request() +struct msgb *gsm0808_create_classmark_request(void) { struct msgb *msg = msgb_alloc_headroom(BSSMAP_MSG_SIZE, BSSMAP_MSG_HEADROOM, "classmark-request"); @@ -1110,7 +1110,7 @@ struct msgb *gsm0808_create_handover_command(const struct gsm0808_handover_comma /*! Create BSSMAP HANDOVER DETECT message, 3GPP TS 48.008 3.2.1.40. * Sent from the MT BSC back to the MSC when the MS has sent a handover RACH request and the MT BSC has * received the Handover Detect message. */ -struct msgb *gsm0808_create_handover_detect() +struct msgb *gsm0808_create_handover_detect(void) { struct msgb *msg; @@ -1129,7 +1129,7 @@ struct msgb *gsm0808_create_handover_detect() /*! Create BSSMAP HANDOVER SUCCEEDED message, 3GPP TS 48.008 3.2.1.13. * Sent from the MSC back to the old BSS to notify that the MS has successfully accessed the new BSS. */ -struct msgb *gsm0808_create_handover_succeeded() +struct msgb *gsm0808_create_handover_succeeded(void) { struct msgb *msg; diff --git a/src/select.c b/src/select.c index 735ea3ef..5aee7d8c 100644 --- a/src/select.c +++ b/src/select.c @@ -653,20 +653,20 @@ osmo_signalfd_setup(void *ctx, sigset_t set, osmo_signalfd_cb *cb, void *data) * } * } */ -void osmo_select_shutdown_request() +void osmo_select_shutdown_request(void) { _osmo_select_shutdown_requested++; }; /*! Return the number of times osmo_select_shutdown_request() was called before. */ -int osmo_select_shutdown_requested() +int osmo_select_shutdown_requested(void) { return _osmo_select_shutdown_requested; }; /*! Return true after osmo_select_shutdown_requested() was called, and after an osmo_select poll loop found no more * pending OSMO_FD_WRITE on any registered socket. */ -bool osmo_select_shutdown_done() { +bool osmo_select_shutdown_done(void) { return _osmo_select_shutdown_done; }; diff --git a/src/time_cc.c b/src/time_cc.c index 05971fe8..0e6879e5 100644 --- a/src/time_cc.c +++ b/src/time_cc.c @@ -49,7 +49,7 @@ OSMO_MIN((TIME_CC)->cfg.round_threshold_usec, GRAN_USEC(TIME_CC)) \ : (GRAN_USEC(TIME_CC) / 2)) -static uint64_t time_now_usec() +static uint64_t time_now_usec(void) { struct timespec tp; if (osmo_clock_gettime(CLOCK_MONOTONIC, &tp)) 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); diff --git a/tests/abis/abis_test.c b/tests/abis/abis_test.c index 8ba5f172..563363d3 100644 --- a/tests/abis/abis_test.c +++ b/tests/abis/abis_test.c @@ -167,7 +167,7 @@ static inline void chk_descr(struct msgb *msg, const char *f_id, const char *f_v } } -static void test_sw_descr() +static void test_sw_descr(void) { const char *f_id = "TEST.L0L", *f_ver = "0.1.666~deadbeeffacefeed-dirty"; uint8_t chain[] = { 0x42, 0x12, 0x00, 0x03, 0x01, 0x02, 0x03, 0x13, 0x00, 0x03, 0x03, 0x04, 0x05, 0x42, 0x12, @@ -194,7 +194,7 @@ static void test_sw_descr() } /* Test decode IPAC_DLCX_IND obtained from SYS#5915 */ -static void test_dec_ipac_dlc_indx() +static void test_dec_ipac_dlc_indx(void) { /* Radio Signalling Link (RSL) 0111 111. = Message discriminator: ip.access Vendor Specific messages (63) diff --git a/tests/bitvec/bitvec_test.c b/tests/bitvec/bitvec_test.c index ea7ea9a4..29c3e33d 100644 --- a/tests/bitvec/bitvec_test.c +++ b/tests/bitvec/bitvec_test.c @@ -69,7 +69,7 @@ static inline void test_set(struct bitvec *bv, enum bit_value bit) printf(" %s [%d]\n\n", lol, bv->cur_bit); } -static void test_byte_ops() +static void test_byte_ops(void) { struct bitvec bv; const uint8_t *in = (const uint8_t *)"ABCDEFGHIJKLMNOPQRSTUVWXYZ"; @@ -162,7 +162,7 @@ static inline void test_bitvec_rl_curbit(struct bitvec *bv, bool b, int max_bits OSMO_ASSERT(num == result); } -static void test_array() +static void test_array(void) { struct bitvec b; uint8_t d[4096]; @@ -181,7 +181,7 @@ static void test_array() test_array_item(17, &b, n, array, n * 3); } -static void test_used_bytes() +static void test_used_bytes(void) { struct bitvec b; uint8_t d[32]; @@ -204,7 +204,7 @@ static void test_used_bytes() } } -static void test_tailroom() +static void test_tailroom(void) { struct bitvec b; uint8_t d[32]; diff --git a/tests/bsslap/bsslap_test.c b/tests/bsslap/bsslap_test.c index f20f7db4..fc5ce754 100644 --- a/tests/bsslap/bsslap_test.c +++ b/tests/bsslap/bsslap_test.c @@ -48,7 +48,7 @@ struct bsslap_pdu bsslap_test_pdus[] = { }, }; -void test_bsslap_enc_dec() +void test_bsslap_enc_dec(void) { struct bsslap_pdu *pdu; printf("--- %s\n", __func__); @@ -96,7 +96,7 @@ loop_end: } } -int main() +int main(int argc, char **argv) { test_bsslap_enc_dec(); return 0; diff --git a/tests/bssmap_le/bssmap_le_test.c b/tests/bssmap_le/bssmap_le_test.c index 08ed4c6e..a14c38a3 100644 --- a/tests/bssmap_le/bssmap_le_test.c +++ b/tests/bssmap_le/bssmap_le_test.c @@ -150,7 +150,7 @@ struct bssmap_le_pdu bssmap_le_test_pdus[] = { }, }; -void test_bssmap_le_enc_dec() +void test_bssmap_le_enc_dec(void) { struct bssmap_le_pdu *pdu; printf("--- %s\n", __func__); @@ -200,7 +200,7 @@ loop_end: } } -int main() +int main(int argc, char **argv) { test_bssmap_le_enc_dec(); return 0; diff --git a/tests/codec/codec_ecu_fr_test.c b/tests/codec/codec_ecu_fr_test.c index 4040ce94..a9dae896 100644 --- a/tests/codec/codec_ecu_fr_test.c +++ b/tests/codec/codec_ecu_fr_test.c @@ -183,7 +183,7 @@ void test_fr_concealment_core(void) } /* Simulate a real life situation: voice frames with a few dropouts */ -void test_fr_concealment_realistic() +void test_fr_concealment_realistic(void) { struct osmo_ecu_fr_state state; uint8_t frame[GSM_FR_BYTES]; @@ -219,7 +219,7 @@ void test_fr_concealment_realistic() } /* Simulate a real life situation: voice frames with a few dropouts, using generic core */ -void test_fr_concealment_realistic_core() +void test_fr_concealment_realistic_core(void) { struct osmo_ecu_state *state = osmo_ecu_init(NULL, OSMO_ECU_CODEC_FR); uint8_t frame[GSM_FR_BYTES]; diff --git a/tests/ctrl/ctrl_test.c b/tests/ctrl/ctrl_test.c index 01fb9f71..1d4d4d74 100644 --- a/tests/ctrl/ctrl_test.c +++ b/tests/ctrl/ctrl_test.c @@ -334,7 +334,7 @@ static const struct one_test test_messages_list[] = { }, }; -static void test_messages() +static void test_messages(void) { struct ctrl_handle *ctrl; struct ctrl_connection *ccon; @@ -390,7 +390,7 @@ static int verify_test_defer(struct ctrl_cmd *cmd, const char *value, void *data return 0; } -static void test_deferred_cmd() +static void test_deferred_cmd(void) { struct ctrl_handle *ctrl; struct ctrl_connection *ccon; diff --git a/tests/fr/fr_test.c b/tests/fr/fr_test.c index 3fb18f3c..cdcdb434 100644 --- a/tests/fr/fr_test.c +++ b/tests/fr/fr_test.c @@ -52,7 +52,7 @@ int socket(int domain, int type, int protocol) return fd; } -void bssgp_prim_cb() +void bssgp_prim_cb(void) { } diff --git a/tests/fsm/fsm_dealloc_test.c b/tests/fsm/fsm_dealloc_test.c index f4be93dd..246ba563 100644 --- a/tests/fsm/fsm_dealloc_test.c +++ b/tests/fsm/fsm_dealloc_test.c @@ -290,7 +290,7 @@ void obj_set_other(struct obj *a, struct obj *b) obj_add_other(b, a); } -static struct scene *scene_alloc() +static struct scene *scene_alloc(void) { struct scene *s = talloc_zero(ctx, struct scene); s->use_count.talloc_object = s; @@ -419,7 +419,7 @@ static void trigger_tests(void *loop_ctx) } } -void test_osmo_fsm_term_safely() +void test_osmo_fsm_term_safely(void) { fprintf(stderr, "\n\n%s()\n", __func__); osmo_fsm_term_safely(true); @@ -428,7 +428,7 @@ void test_osmo_fsm_term_safely() fprintf(stderr, "\n\n%s() done\n", __func__); } -void test_osmo_fsm_set_dealloc_ctx() +void test_osmo_fsm_set_dealloc_ctx(void) { fprintf(stderr, "\n\n%s()\n", __func__); void *dealloc_ctx = talloc_named_const(ctx, 0, "fsm_dealloc"); diff --git a/tests/fsm/fsm_test.c b/tests/fsm/fsm_test.c index 6fa0ae71..960042c7 100644 --- a/tests/fsm/fsm_test.c +++ b/tests/fsm/fsm_test.c @@ -172,7 +172,7 @@ static struct osmo_fsm_inst *foo(void) return fi; } -static void test_id_api() +static void test_id_api(void) { struct osmo_fsm_inst *fi; @@ -280,7 +280,7 @@ const struct timeval fake_time_start_time = { 123, 456 }; osmo_timers_update(); \ } while (0) -void fake_time_start() +void fake_time_start(void) { struct timespec *clock_override; @@ -301,7 +301,7 @@ static int timer_cb(struct osmo_fsm_inst *fi) return 0; } -static void test_state_chg_keep_timer() +static void test_state_chg_keep_timer(void) { struct osmo_fsm_inst *fi; @@ -349,7 +349,7 @@ static void test_state_chg_keep_timer() fprintf(stderr, "--- %s() done\n", __func__); } -static void test_state_chg_T() +static void test_state_chg_T(void) { struct osmo_fsm_inst *fi; diff --git a/tests/gad/gad_test.c b/tests/gad/gad_test.c index ca8c4fa8..19be6a61 100644 --- a/tests/gad/gad_test.c +++ b/tests/gad/gad_test.c @@ -4,7 +4,7 @@ #include <osmocom/core/msgb.h> #include <osmocom/gsm/gad.h> -void test_gad_lat_lon_dec_enc_stability() +void test_gad_lat_lon_dec_enc_stability(void) { uint32_t lat_enc; uint32_t lon_enc; @@ -49,7 +49,7 @@ struct osmo_gad gad_test_values[] = { }, }; -void test_gad_enc_dec() +void test_gad_enc_dec(void) { int i; printf("--- %s\n", __func__); @@ -115,7 +115,7 @@ loop_end: } } -void test_gad_to_str() +void test_gad_to_str(void) { int i; printf("--- %s\n", __func__); @@ -134,7 +134,7 @@ void test_gad_to_str() } } -int main() +int main(int argc, char **argv) { test_gad_lat_lon_dec_enc_stability(); test_gad_enc_dec(); diff --git a/tests/gb/gprs_bssgp_rim_test.c b/tests/gb/gprs_bssgp_rim_test.c index e2d4f661..bb533f6d 100644 --- a/tests/gb/gprs_bssgp_rim_test.c +++ b/tests/gb/gprs_bssgp_rim_test.c @@ -60,7 +60,7 @@ void dump_rim_ri(struct bssgp_rim_routing_info *ri) } } -static void test_bssgp_parse_rim_ri() +static void test_bssgp_parse_rim_ri(void) { int rc; struct bssgp_rim_routing_info result; @@ -94,7 +94,7 @@ static void test_bssgp_parse_rim_ri() printf("----- %s END\n", __func__); } -static void test_bssgp_create_rim_ri() +static void test_bssgp_create_rim_ri(void) { int rc; struct bssgp_rim_routing_info ri; @@ -194,7 +194,7 @@ void dump_bssgp_ran_inf_req_rim_cont(struct bssgp_ran_inf_req_rim_cont *rim_cont } } -static void test_bssgp_dec_ran_inf_req_rim_cont_nacc() +static void test_bssgp_dec_ran_inf_req_rim_cont_nacc(void) { int rc; struct bssgp_ran_inf_req_rim_cont rim_cont_dec; @@ -212,7 +212,7 @@ static void test_bssgp_dec_ran_inf_req_rim_cont_nacc() printf("----- %s END\n", __func__); } -static void test_bssgp_enc_ran_inf_req_rim_cont_nacc() +static void test_bssgp_enc_ran_inf_req_rim_cont_nacc(void) { int rc; struct bssgp_ran_inf_req_rim_cont rim_cont = { }; @@ -321,7 +321,7 @@ static void dump_bssgp_ran_inf_rim_cont(struct bssgp_ran_inf_rim_cont *rim_cont) } } -static void test_bssgp_dec_ran_inf_rim_cont_nacc() +static void test_bssgp_dec_ran_inf_rim_cont_nacc(void) { int rc; struct bssgp_ran_inf_rim_cont rim_cont_dec; @@ -346,7 +346,7 @@ static void test_bssgp_dec_ran_inf_rim_cont_nacc() printf("----- %s END\n", __func__); } -static void test_bssgp_dec_ran_inf_rim_cont_err_nacc() +static void test_bssgp_dec_ran_inf_rim_cont_err_nacc(void) { int rc; struct bssgp_ran_inf_rim_cont rim_cont_dec; @@ -364,7 +364,7 @@ static void test_bssgp_dec_ran_inf_rim_cont_err_nacc() printf("----- %s END\n", __func__); } -static void test_bssgp_enc_ran_inf_rim_cont_nacc() +static void test_bssgp_enc_ran_inf_rim_cont_nacc(void) { int rc; struct bssgp_ran_inf_rim_cont rim_cont = { }; @@ -415,7 +415,7 @@ static void test_bssgp_enc_ran_inf_rim_cont_nacc() printf("----- %s END\n", __func__); } -static void test_bssgp_enc_ran_inf_rim_cont_err_nacc() +static void test_bssgp_enc_ran_inf_rim_cont_err_nacc(void) { int rc; struct bssgp_ran_inf_rim_cont rim_cont = { }; @@ -458,7 +458,7 @@ static void dump_bssgp_ran_inf_ack_rim_cont(struct bssgp_ran_inf_ack_rim_cont *r } } -static void test_bssgp_dec_ran_inf_ack_rim_cont() +static void test_bssgp_dec_ran_inf_ack_rim_cont(void) { int rc; struct bssgp_ran_inf_ack_rim_cont rim_cont_dec; @@ -474,7 +474,7 @@ static void test_bssgp_dec_ran_inf_ack_rim_cont() printf("----- %s END\n", __func__); } -static void test_bssgp_enc_ran_inf_ack_rim_cont() +static void test_bssgp_enc_ran_inf_ack_rim_cont(void) { int rc; struct bssgp_ran_inf_ack_rim_cont rim_cont = { }; @@ -513,7 +513,7 @@ void dump_bssgp_ran_inf_err_rim_cont(struct bssgp_ran_inf_err_rim_cont *rim_cont } } -static void test_bssgp_dec_ran_inf_err_rim_cont() +static void test_bssgp_dec_ran_inf_err_rim_cont(void) { int rc; struct bssgp_ran_inf_err_rim_cont rim_cont_dec; @@ -530,7 +530,7 @@ static void test_bssgp_dec_ran_inf_err_rim_cont() printf("----- %s END\n", __func__); } -static void test_bssgp_enc_ran_inf_err_rim_cont() +static void test_bssgp_enc_ran_inf_err_rim_cont(void) { int rc; struct bssgp_ran_inf_err_rim_cont rim_cont = { }; @@ -578,7 +578,7 @@ void dump_bssgp_ran_inf_app_err_rim_cont(struct bssgp_ran_inf_app_err_rim_cont * } } -static void test_bssgp_dec_ran_inf_app_err_rim_cont_nacc() +static void test_bssgp_dec_ran_inf_app_err_rim_cont_nacc(void) { int rc; struct bssgp_ran_inf_app_err_rim_cont rim_cont_dec; @@ -597,7 +597,7 @@ static void test_bssgp_dec_ran_inf_app_err_rim_cont_nacc() printf("----- %s END\n", __func__); } -static void test_bssgp_enc_ran_inf_app_err_rim_cont_nacc() +static void test_bssgp_enc_ran_inf_app_err_rim_cont_nacc(void) { int rc; struct bssgp_ran_inf_app_err_rim_cont rim_cont = { }; @@ -623,7 +623,7 @@ static void test_bssgp_enc_ran_inf_app_err_rim_cont_nacc() printf("----- %s END\n", __func__); } -static void test_bssgp_dec_ran_inf_req_app_cont_nacc() +static void test_bssgp_dec_ran_inf_req_app_cont_nacc(void) { int rc; struct bssgp_ran_inf_req_app_cont_nacc app_cont_dec; @@ -639,7 +639,7 @@ static void test_bssgp_dec_ran_inf_req_app_cont_nacc() printf("----- %s END\n", __func__); } -static void test_bssgp_enc_ran_inf_req_app_cont_nacc() +static void test_bssgp_enc_ran_inf_req_app_cont_nacc(void) { int rc; struct bssgp_ran_inf_req_app_cont_nacc app_cont = { }; @@ -662,7 +662,7 @@ static void test_bssgp_enc_ran_inf_req_app_cont_nacc() printf("----- %s END\n", __func__); } -static void test_bssgp_dec_ran_inf_app_cont_nacc() +static void test_bssgp_dec_ran_inf_app_cont_nacc(void) { int rc; struct bssgp_ran_inf_app_cont_nacc app_cont_dec; @@ -682,7 +682,7 @@ static void test_bssgp_dec_ran_inf_app_cont_nacc() printf("----- %s END\n", __func__); } -static void test_bssgp_enc_ran_inf_app_cont_nacc() +static void test_bssgp_enc_ran_inf_app_cont_nacc(void) { int rc; struct bssgp_ran_inf_app_cont_nacc app_cont = { }; @@ -721,7 +721,7 @@ static void test_bssgp_enc_ran_inf_app_cont_nacc() printf("----- %s END\n", __func__); } -static void test_bssgp_dec_app_err_cont_nacc() +static void test_bssgp_dec_app_err_cont_nacc(void) { int rc; struct bssgp_app_err_cont_nacc app_cont_dec; @@ -737,7 +737,7 @@ static void test_bssgp_dec_app_err_cont_nacc() printf("----- %s END\n", __func__); } -static void test_bssgp_enc_app_err_cont_nacc() +static void test_bssgp_enc_app_err_cont_nacc(void) { int rc; struct bssgp_app_err_cont_nacc app_cont = { }; diff --git a/tests/gb/gprs_bssgp_test.c b/tests/gb/gprs_bssgp_test.c index 43fc056c..775ae43b 100644 --- a/tests/gb/gprs_bssgp_test.c +++ b/tests/gb/gprs_bssgp_test.c @@ -173,7 +173,7 @@ static void test_bssgp_status(void) printf("----- %s END\n", __func__); } -static void test_bssgp_bad_reset() +static void test_bssgp_bad_reset(void) { struct msgb *msg; uint16_t bvci_be = htons(2); @@ -256,7 +256,7 @@ static void test_bssgp_flow_control_bvc(void) printf("----- %s END\n", __func__); } -static void test_bssgp_msgb_copy() +static void test_bssgp_msgb_copy(void) { struct msgb *msg, *msg2; uint16_t bvci_be = htons(2); diff --git a/tests/gb/gprs_ns_test.c b/tests/gb/gprs_ns_test.c index 6ced6a3b..fc1ec605 100644 --- a/tests/gb/gprs_ns_test.c +++ b/tests/gb/gprs_ns_test.c @@ -420,7 +420,7 @@ static int expire_nsvc_timer(struct gprs_nsvc *nsvc) return rc; } -static void test_nsvc() +static void test_nsvc(void) { struct gprs_ns_inst *nsi = gprs_ns_instantiate(gprs_ns_callback, NULL); struct sockaddr_in peer[1] = {{0},}; @@ -459,7 +459,7 @@ static void test_nsvc() alarm(0); } -static void test_ignored_messages() +static void test_ignored_messages(void) { struct gprs_ns_inst *nsi = gprs_ns_instantiate(gprs_ns_callback, NULL); struct sockaddr_in peer[1] = {{0},}; @@ -486,7 +486,7 @@ static void test_ignored_messages() nsi = NULL; } -static void test_bss_port_changes() +static void test_bss_port_changes(void) { struct gprs_ns_inst *nsi = gprs_ns_instantiate(gprs_ns_callback, NULL); struct sockaddr_in peer[4] = {{0},}; @@ -540,7 +540,7 @@ static void test_bss_port_changes() nsi = NULL; } -static void test_bss_reset_ack() +static void test_bss_reset_ack(void) { struct gprs_ns_inst *nsi = gprs_ns_instantiate(gprs_ns_callback, NULL); struct sockaddr_in peer[4] = {{0},}; @@ -687,7 +687,7 @@ static void test_bss_reset_ack() } -static void test_sgsn_reset() +static void test_sgsn_reset(void) { struct gprs_ns_inst *nsi = gprs_ns_instantiate(gprs_ns_callback, NULL); struct sockaddr_in sgsn_peer= {0}; @@ -765,7 +765,7 @@ static void test_sgsn_reset() nsi = NULL; } -static void test_sgsn_reset_invalid_state() +static void test_sgsn_reset_invalid_state(void) { struct gprs_ns_inst *nsi = gprs_ns_instantiate(gprs_ns_callback, NULL); struct sockaddr_in sgsn_peer= {0}; @@ -833,7 +833,7 @@ static void test_sgsn_reset_invalid_state() nsi = NULL; } -static void test_sgsn_output() +static void test_sgsn_output(void) { struct gprs_ns_inst *nsi = gprs_ns_instantiate(gprs_ns_callback, NULL); struct sockaddr_in sgsn_peer= {0}; diff --git a/tests/gsm0408/gsm0408_test.c b/tests/gsm0408/gsm0408_test.c index 38200c70..a2267184 100644 --- a/tests/gsm0408/gsm0408_test.c +++ b/tests/gsm0408/gsm0408_test.c @@ -90,7 +90,7 @@ static const struct bcap_test bcap_tests[] = { { speech_no3a_lv, &bcap_speech_no3a, "Speech, without octet 3a" }, }; -static int test_bearer_cap() +static int test_bearer_cap(void) { struct gsm_mncc_bearer_cap bc; int i, rc; @@ -1154,7 +1154,7 @@ struct mobile_identity_tc mobile_identity_tests[] = { }, }; -void test_struct_mobile_identity() +void test_struct_mobile_identity(void) { struct mobile_identity_tc *t; printf("%s()\n", __func__); @@ -1316,7 +1316,7 @@ static const struct bcd_number_test { }, }; -static void test_bcd_number_encode_decode() +static void test_bcd_number_encode_decode(void) { const struct bcd_number_test *test; uint8_t buf_enc[0xff] = { 0xff }; @@ -1550,7 +1550,7 @@ static void test_random_range_encoding(int range, int max_arfcn_num) } } -static void test_range_encoding() +static void test_range_encoding(void) { int *arfcns; int arfcns_num = 0; @@ -1611,7 +1611,7 @@ static int range512[] = { __FILE__, __LINE__, (int) res, # cmp, (int) wanted); \ } -static void test_arfcn_filter() +static void test_arfcn_filter(void) { int arfcns[50], i, res, f0_included; for (i = 0; i < ARRAY_SIZE(arfcns); ++i) @@ -1644,7 +1644,7 @@ static void test_arfcn_filter() VERIFY(arfcns[i], ==, ((i + 1) * 2) - 1); } -static void test_print_encoding() +static void test_print_encoding(void) { int rc; int w[17]; @@ -1669,7 +1669,7 @@ static void test_print_encoding() printf("Range512: %s\n", osmo_hexdump(chan_list, ARRAY_SIZE(chan_list))); } -static void test_si_range_helpers() +static void test_si_range_helpers(void) { int ws[(sizeof(freqs1)/sizeof(freqs1[0]))]; int i, f0 = 0xFFFFFF; @@ -1708,7 +1708,7 @@ static void test_si_range_helpers() VERIFY(f0, ==, 1); } -static void test_power_ctrl() +static void test_power_ctrl(void) { int8_t rc8; int rc; @@ -1750,7 +1750,7 @@ static void test_power_ctrl() VERIFY(rc, <, 0); } -static void test_rach_tx_integer_raw2val() +static void test_rach_tx_integer_raw2val(void) { unsigned int raw; for (raw = 0; raw <= 0x0f; raw++) { diff --git a/tests/gsm0502/gsm0502_test.c b/tests/gsm0502/gsm0502_test.c index f4f6530e..e9deaa9f 100644 --- a/tests/gsm0502/gsm0502_test.c +++ b/tests/gsm0502/gsm0502_test.c @@ -86,7 +86,7 @@ uint32_t facch_h1_fn_samples[] = { 500728, 500771, 500797, 500841, 500875, 50091 502782, 502825, 502869, 502903, 502955, 502999 }; -static void test_gsm0502_fn_remap() +static void test_gsm0502_fn_remap(void) { unsigned int i; uint32_t fn_begin; diff --git a/tests/gsm0808/gsm0808_test.c b/tests/gsm0808/gsm0808_test.c index b3aa3ab8..2734f913 100644 --- a/tests/gsm0808/gsm0808_test.c +++ b/tests/gsm0808/gsm0808_test.c @@ -111,7 +111,7 @@ static void test_create_layer3(void) msgb_free(in_msg); } -static void test_create_layer3_aoip() +static void test_create_layer3_aoip(void) { static const uint8_t res[] = { 0x00, 0x17, 0x57, 0x05, 0x08, 0x00, 0x77, 0x62, @@ -148,7 +148,7 @@ static void test_create_layer3_aoip() msgb_free(in_msg); } -static void test_create_reset() +static void test_create_reset(void) { static const uint8_t res[] = { 0x00, 0x04, 0x30, 0x04, 0x01, 0x20 }; struct msgb *msg; @@ -159,7 +159,7 @@ static void test_create_reset() msgb_free(msg); } -static void test_create_reset_ack() +static void test_create_reset_ack(void) { static const uint8_t res[] = { 0x00, 0x01, 0x31 }; struct msgb *msg; @@ -171,7 +171,7 @@ static void test_create_reset_ack() } -static void test_create_clear_command() +static void test_create_clear_command(void) { static const uint8_t res[] = { 0x20, 0x04, 0x01, 0x23 }; struct msgb *msg; @@ -182,7 +182,7 @@ static void test_create_clear_command() msgb_free(msg); } -static void test_create_clear_command2() +static void test_create_clear_command2(void) { static const uint8_t res[] = { 0x00, 0x04, 0x20, 0x04, 0x01, 0x23 }; struct msgb *msg; @@ -193,7 +193,7 @@ static void test_create_clear_command2() msgb_free(msg); } -static void test_create_clear_command2_csfb() +static void test_create_clear_command2_csfb(void) { static const uint8_t res[] = { 0x00, 0x05, 0x20, 0x04, 0x01, 0x23, 0x8F }; struct msgb *msg; @@ -204,7 +204,7 @@ static void test_create_clear_command2_csfb() msgb_free(msg); } -static void test_create_clear_complete() +static void test_create_clear_complete(void) { static const uint8_t res[] = { 0x00, 0x01, 0x21 }; struct msgb *msg; @@ -215,7 +215,7 @@ static void test_create_clear_complete() msgb_free(msg); } -static void test_create_cipher() +static void test_create_cipher(void) { static const uint8_t res[] = { 0x00, 0x0c, 0x53, 0x0a, 0x09, 0x03, 0xaa, @@ -255,7 +255,7 @@ static void test_create_cipher() msgb_free(msg); } -static void test_create_cipher_complete() +static void test_create_cipher_complete(void) { static const uint8_t res1[] = { 0x00, 0x08, 0x55, 0x20, 0x03, 0x23, 0x42, 0x21, 0x2c, 0x04 }; @@ -312,7 +312,7 @@ static inline void parse_cipher_reject(struct msgb *msg, uint8_t exp) rc, exp, OSMO_BIT_PRINT(exp), msgb_hexdump(msg)); } -static void test_create_cipher_reject() +static void test_create_cipher_reject(void) { static const uint8_t res[] = { 0x00, 0x04, 0x59, 0x04, 0x01, 0x23 }; enum gsm0808_cause cause = GSM0808_CAUSE_CCCH_OVERLOAD; @@ -327,7 +327,7 @@ static void test_create_cipher_reject() msgb_free(msg); } -static void test_create_cipher_reject_ext() +static void test_create_cipher_reject_ext(void) { static const uint8_t res[] = { 0x00, 0x05, 0x59, 0x04, 0x02, 0xd0, 0xFA }; uint8_t cause = 0xFA; @@ -342,7 +342,7 @@ static void test_create_cipher_reject_ext() msgb_free(msg); } -static void test_create_cm_u() +static void test_create_cm_u(void) { static const uint8_t res[] = { 0x00, 0x07, 0x54, 0x12, 0x01, 0x23, 0x13, 0x01, 0x42 }; @@ -364,7 +364,7 @@ static void test_create_cm_u() msgb_free(msg); } -static void test_create_sapi_reject() +static void test_create_sapi_reject(void) { static const uint8_t res[] = { 0x00, 0x06, 0x25, 0x18, 0x03, 0x04, 0x01, 0x25 }; struct msgb *msg; @@ -375,7 +375,7 @@ static void test_create_sapi_reject() msgb_free(msg); } -static void test_dec_confusion() +static void test_dec_confusion(void) { static const uint8_t hex[] = { 0x26, 0x04, 0x01, 0x52, 0x1f, 0x07, 0x00, 0xff, 0x00, 0x03, 0x25, 0x03, 0x25 }; @@ -425,7 +425,7 @@ static void test_dec_confusion() } /* Test Perform Location Report SYS#5891 */ -static void test_dec_perform_location_report_sys5891() +static void test_dec_perform_location_report_sys5891(void) { /* Message Type Perform Location Request Location Type @@ -477,7 +477,7 @@ static void test_dec_perform_location_report_sys5891() OSMO_ASSERT(rc == 5); } -static void test_create_ass() +static void test_create_ass(void) { static const uint8_t res1[] = { 0x00, 0x0a, 0x01, 0x0b, 0x04, 0x01, 0x0b, 0xa1, 0x25, 0x01, 0x00, @@ -527,7 +527,7 @@ static void test_create_ass() msgb_free(msg); } -static void test_create_ass2() +static void test_create_ass2(void) { static const uint8_t res[] = { BSSAP_MSG_BSS_MANAGEMENT, @@ -604,7 +604,7 @@ static void test_create_ass2() msgb_free(msg); } -static void test_create_ass_compl() +static void test_create_ass_compl(void) { static const uint8_t res1[] = { 0x00, 0x09, 0x02, 0x15, 0x23, 0x21, 0x42, 0x2c, @@ -623,7 +623,7 @@ static void test_create_ass_compl() msgb_free(msg); } -static void test_create_ass_compl_aoip() +static void test_create_ass_compl_aoip(void) { struct sockaddr_storage ss; struct sockaddr_in sin; @@ -660,7 +660,7 @@ static void test_create_ass_compl_aoip() msgb_free(msg); } -static void test_create_ass_fail() +static void test_create_ass_fail(void) { static const uint8_t res1[] = { 0x00, 0x04, 0x03, 0x04, 0x01, 0x23 }; static const uint8_t res2[] = { @@ -678,7 +678,7 @@ static void test_create_ass_fail() msgb_free(msg); } -static void test_create_ass_fail_aoip() +static void test_create_ass_fail_aoip(void) { static const uint8_t res1[] = { 0x00, 0x0d, 0x03, 0x04, 0x01, 0x23, GSM0808_IE_SPEECH_CODEC_LIST, @@ -704,7 +704,7 @@ static void test_create_ass_fail_aoip() msgb_free(msg); } -static void test_create_clear_rqst() +static void test_create_clear_rqst(void) { static const uint8_t res[] = { 0x00, 0x04, 0x22, 0x04, 0x01, 0x23 }; struct msgb *msg; @@ -715,7 +715,7 @@ static void test_create_clear_rqst() msgb_free(msg); } -static void test_create_paging() +static void test_create_paging(void) { static const uint8_t res[] = { 0x00, 0x10, 0x52, 0x08, 0x08, 0x09, 0x10, 0x10, 0x00, 0x00, 0x00, @@ -755,7 +755,7 @@ static void test_create_paging() msgb_free(msg); } -static void test_create_dtap() +static void test_create_dtap(void) { static const uint8_t res[] = { 0x01, 0x03, 0x02, 0x23, 0x42 }; struct msgb *msg, *l3; @@ -772,7 +772,7 @@ static void test_create_dtap() msgb_free(l3); } -static void test_prepend_dtap() +static void test_prepend_dtap(void) { static const uint8_t res[] = { 0x01, 0x03, 0x02, 0x23, 0x42 }; struct msgb *in_msg; @@ -789,7 +789,7 @@ static void test_prepend_dtap() msgb_free(in_msg); } -static void test_enc_dec_lcls() +static void test_enc_dec_lcls(void) { static const uint8_t res[] = { GSM0808_IE_GLOBAL_CALL_REF, @@ -867,7 +867,7 @@ static void test_enc_dec_lcls() msgb_free(msg); } -static void test_enc_dec_aoip_trasp_addr_v4() +static void test_enc_dec_aoip_trasp_addr_v4(void) { struct sockaddr_storage enc_addr; struct sockaddr_storage dec_addr; @@ -895,7 +895,7 @@ static void test_enc_dec_aoip_trasp_addr_v4() msgb_free(msg); } -static void test_enc_dec_aoip_trasp_addr_v6() +static void test_enc_dec_aoip_trasp_addr_v6(void) { struct sockaddr_storage enc_addr; struct sockaddr_storage dec_addr; @@ -924,7 +924,7 @@ static void test_enc_dec_aoip_trasp_addr_v6() msgb_free(msg); } -static void test_enc_aoip_trasp_addr_msg_too_small() +static void test_enc_aoip_trasp_addr_msg_too_small(void) { struct msgb *msg; struct sockaddr_storage enc_addr; @@ -946,7 +946,7 @@ static void test_enc_aoip_trasp_addr_msg_too_small() msgb_free(msg); } -static void test_gsm0808_enc_dec_speech_codec() +static void test_gsm0808_enc_dec_speech_codec(void) { struct gsm0808_speech_codec enc_sc = { .pi = true, @@ -971,7 +971,7 @@ static void test_gsm0808_enc_dec_speech_codec() } -static void test_gsm0808_enc_dec_speech_codec_with_cfg() +static void test_gsm0808_enc_dec_speech_codec_with_cfg(void) { struct gsm0808_speech_codec enc_sc = { .pi = true, @@ -996,7 +996,7 @@ static void test_gsm0808_enc_dec_speech_codec_with_cfg() msgb_free(msg); } -static void test_gsm0808_enc_dec_speech_codec_ext_with_cfg() +static void test_gsm0808_enc_dec_speech_codec_ext_with_cfg(void) { struct gsm0808_speech_codec enc_sc = { .pi = true, @@ -1021,7 +1021,7 @@ static void test_gsm0808_enc_dec_speech_codec_ext_with_cfg() msgb_free(msg); } -static void test_gsm0808_enc_dec_speech_codec_list() +static void test_gsm0808_enc_dec_speech_codec_list(void) { struct gsm0808_speech_codec_list enc_scl = { .codec = { @@ -1064,7 +1064,7 @@ static void test_gsm0808_enc_dec_speech_codec_list() msgb_free(msg); } -static void test_gsm0808_enc_dec_empty_speech_codec_list() +static void test_gsm0808_enc_dec_empty_speech_codec_list(void) { struct gsm0808_speech_codec_list enc_scl = { .len = 0, @@ -1086,7 +1086,7 @@ static void test_gsm0808_enc_dec_empty_speech_codec_list() msgb_free(msg); } -static void test_gsm0808_enc_dec_channel_type() +static void test_gsm0808_enc_dec_channel_type(void) { struct gsm0808_channel_type enc_ct = { .ch_indctr = GSM0808_CHAN_SPEECH, @@ -1117,7 +1117,7 @@ static void test_gsm0808_enc_dec_channel_type() msgb_free(msg); } -static void test_gsm0808_enc_dec_encrypt_info() +static void test_gsm0808_enc_dec_encrypt_info(void) { struct gsm0808_encrypt_info enc_ei = { .perm_algo = { GSM0808_ALG_ID_A5_0, GSM0808_ALG_ID_A5_1 }, @@ -1147,7 +1147,7 @@ static void test_gsm0808_enc_dec_encrypt_info() msgb_free(msg); } -static void test_gsm0808_dec_cell_id_list_srvcc() +static void test_gsm0808_dec_cell_id_list_srvcc(void) { /* taken from a pcap file of a real-world 3rd party MSC (SYS#5838) */ const uint8_t enc_cil[] = { 0x0b, 0x2, 0xf2, 0x10, 0x4e, 0x20, 0x15, 0xbe}; @@ -1160,7 +1160,7 @@ static void test_gsm0808_dec_cell_id_list_srvcc() OSMO_ASSERT(dec_cil.id_list_len = 1); } -static void test_gsm0808_enc_dec_cell_id_list_lac() +static void test_gsm0808_enc_dec_cell_id_list_lac(void) { struct gsm0808_cell_id_list2 enc_cil; struct gsm0808_cell_id_list2 dec_cil; @@ -1187,7 +1187,7 @@ static void test_gsm0808_enc_dec_cell_id_list_lac() msgb_free(msg); } -static void test_gsm0808_enc_dec_cell_id_list_single_lac() +static void test_gsm0808_enc_dec_cell_id_list_single_lac(void) { struct gsm0808_cell_id_list2 enc_cil; struct gsm0808_cell_id_list2 dec_cil; @@ -1216,7 +1216,7 @@ static void test_gsm0808_enc_dec_cell_id_list_single_lac() msgb_free(msg); } -static void test_gsm0808_enc_dec_cell_id_list_multi_lac() +static void test_gsm0808_enc_dec_cell_id_list_multi_lac(void) { struct gsm0808_cell_id_list2 enc_cil; struct gsm0808_cell_id_list2 dec_cil; @@ -1252,7 +1252,7 @@ static void test_gsm0808_enc_dec_cell_id_list_multi_lac() msgb_free(msg); } -static void test_gsm0808_enc_dec_cell_id_list_bss() +static void test_gsm0808_enc_dec_cell_id_list_bss(void) { struct gsm0808_cell_id_list2 enc_cil; struct gsm0808_cell_id_list2 dec_cil; @@ -1275,7 +1275,7 @@ static void test_gsm0808_enc_dec_cell_id_list_bss() msgb_free(msg); } -static void test_gsm0808_enc_dec_cell_id_list_multi_lai_and_lac() +static void test_gsm0808_enc_dec_cell_id_list_multi_lai_and_lac(void) { struct gsm0808_cell_id_list2 enc_cil; struct gsm0808_cell_id_list2 dec_cil; @@ -1331,7 +1331,7 @@ static void test_gsm0808_enc_dec_cell_id_list_multi_lai_and_lac() msgb_free(msg); } -static void test_gsm0808_enc_dec_cell_id_list_multi_ci() +static void test_gsm0808_enc_dec_cell_id_list_multi_ci(void) { struct gsm0808_cell_id_list2 enc_cil; struct gsm0808_cell_id_list2 dec_cil; @@ -1365,7 +1365,7 @@ static void test_gsm0808_enc_dec_cell_id_list_multi_ci() msgb_free(msg); } -static void test_gsm0808_enc_dec_cell_id_list_multi_lac_and_ci() +static void test_gsm0808_enc_dec_cell_id_list_multi_lac_and_ci(void) { struct gsm0808_cell_id_list2 enc_cil; struct gsm0808_cell_id_list2 dec_cil; @@ -1406,7 +1406,7 @@ static void test_gsm0808_enc_dec_cell_id_list_multi_lac_and_ci() msgb_free(msg); } -static void test_gsm0808_enc_dec_cell_id_list_multi_global() +static void test_gsm0808_enc_dec_cell_id_list_multi_global(void) { struct gsm0808_cell_id_list2 enc_cil; struct gsm0808_cell_id_list2 dec_cil; @@ -1479,7 +1479,7 @@ static void print_cil(const struct gsm0808_cell_id_list2 *cil) printf(" cell_id_list == %s\n", gsm0808_cell_id_list_name(cil)); } -void test_cell_id_list_add() { +void test_cell_id_list_add(void) { size_t zu; const struct gsm0808_cell_id_list2 cgi1 = { @@ -1661,7 +1661,7 @@ void test_cell_id_list_add() { printf("------- %s done\n", __func__); } -static void test_gsm0808_enc_dec_cell_id_lac() +static void test_gsm0808_enc_dec_cell_id_lac(void) { struct gsm0808_cell_id enc_ci = { .id_discr = CELL_IDENT_LAC, @@ -1687,7 +1687,7 @@ static void test_gsm0808_enc_dec_cell_id_lac() msgb_free(msg); } -static void test_gsm0808_enc_dec_cell_id_bss() +static void test_gsm0808_enc_dec_cell_id_bss(void) { struct gsm0808_cell_id enc_ci = { .id_discr = CELL_IDENT_BSS, @@ -1709,7 +1709,7 @@ static void test_gsm0808_enc_dec_cell_id_bss() msgb_free(msg); } -static void test_gsm0808_enc_dec_cell_id_no_cell() +static void test_gsm0808_enc_dec_cell_id_no_cell(void) { struct gsm0808_cell_id enc_ci = { .id_discr = CELL_IDENT_NO_CELL, @@ -1731,7 +1731,7 @@ static void test_gsm0808_enc_dec_cell_id_no_cell() msgb_free(msg); } -static void test_gsm0808_enc_dec_cell_id_lai_and_lac() +static void test_gsm0808_enc_dec_cell_id_lai_and_lac(void) { struct gsm0808_cell_id enc_ci = { .id_discr = CELL_IDENT_LAI_AND_LAC, @@ -1762,7 +1762,7 @@ static void test_gsm0808_enc_dec_cell_id_lai_and_lac() msgb_free(msg); } -static void test_gsm0808_enc_dec_cell_id_ci() +static void test_gsm0808_enc_dec_cell_id_ci(void) { struct gsm0808_cell_id enc_ci = { .id_discr = CELL_IDENT_CI, @@ -1785,7 +1785,7 @@ static void test_gsm0808_enc_dec_cell_id_ci() msgb_free(msg); } -static void test_gsm0808_enc_dec_cell_id_lac_and_ci() +static void test_gsm0808_enc_dec_cell_id_lac_and_ci(void) { struct gsm0808_cell_id enc_ci = { .id_discr = CELL_IDENT_LAC_AND_CI, @@ -1812,7 +1812,7 @@ static void test_gsm0808_enc_dec_cell_id_lac_and_ci() msgb_free(msg); } -static void test_gsm0808_enc_dec_cell_id_global() +static void test_gsm0808_enc_dec_cell_id_global(void) { struct gsm0808_cell_id enc_ci = { .id_discr = CELL_IDENT_WHOLE_GLOBAL, @@ -1844,7 +1844,7 @@ static void test_gsm0808_enc_dec_cell_id_global() msgb_free(msg); } -static void test_gsm0808_enc_dec_cell_id_global_ps() +static void test_gsm0808_enc_dec_cell_id_global_ps(void) { struct gsm0808_cell_id enc_cgi = { .id_discr = CELL_IDENT_WHOLE_GLOBAL, @@ -2130,7 +2130,7 @@ static void test_gsm48_mr_cfg_from_gsm0808_sc_cfg_single(uint16_t s15_s0) printf("\n"); } -void test_gsm48_mr_cfg_from_gsm0808_sc_cfg() +void test_gsm48_mr_cfg_from_gsm0808_sc_cfg(void) { printf("Testing gsm48_mr_cfg_from_gsm0808_sc_cfg():\n"); @@ -2315,7 +2315,7 @@ static const struct test_cell_id_matching_data test_cell_id_matching_tests[] = { { .id = cgi_23_042_23_5, .match_id = cgi_23_99_23_5, .expect_match = false, .expect_exact_match = false }, }; -static void test_cell_id_matching() +static void test_cell_id_matching(void) { int i; bool ok = true; @@ -2478,7 +2478,7 @@ static const struct gsm0808_cell_id test_gsm0808_cell_id_to_from_cgi_data[] = { { .id_discr = 423 }, }; -static void test_gsm0808_cell_id_to_from_cgi() +static void test_gsm0808_cell_id_to_from_cgi(void) { int i; int j; diff --git a/tests/gsm23003/gsm23003_test.c b/tests/gsm23003/gsm23003_test.c index e73ef43a..77d3173e 100644 --- a/tests/gsm23003/gsm23003_test.c +++ b/tests/gsm23003/gsm23003_test.c @@ -54,7 +54,7 @@ static struct { { NULL, false }, }; -bool test_valid_imsi() +bool test_valid_imsi(void) { int i; bool pass = true; @@ -97,7 +97,7 @@ static struct { { NULL, false }, }; -bool test_valid_msisdn() +bool test_valid_msisdn(void) { int i; bool pass = true; @@ -138,7 +138,7 @@ static struct { { NULL, false, false }, }; -bool test_valid_imei() +bool test_valid_imei(void) { int i; bool pass = true; @@ -185,7 +185,7 @@ static struct test_mnc_from_str test_mnc_from_strs[] = { { "023 ", { -EINVAL, 0, false } }, }; -static bool test_mnc_from_str() +static bool test_mnc_from_str(void) { int i; bool pass = true; @@ -209,7 +209,7 @@ static bool test_mnc_from_str() return pass; } -static bool test_gummei_name() +static bool test_gummei_name(void) { static const struct osmo_gummei gummei = { .plmn = { .mcc = 901, .mnc = 70 }, @@ -226,7 +226,7 @@ static bool test_gummei_name() return pass; } -static bool test_domain_gen() +static bool test_domain_gen(void) { static const struct osmo_gummei gummei = { .plmn = { .mcc = 901, .mnc = 70 }, @@ -252,7 +252,7 @@ static bool test_domain_gen() } -static bool test_domain_parse() +static bool test_domain_parse(void) { static const char *mme_dom_valid = "mmec01.mmegiA001.mme.epc.mnc070.mcc901.3gppnetwork.org"; static const char *home_dom_valid = "epc.mnc070.mcc901.3gppnetwork.org"; diff --git a/tests/gsm23236/gsm23236_test.c b/tests/gsm23236/gsm23236_test.c index 77e20e38..6cbdbeb2 100644 --- a/tests/gsm23236/gsm23236_test.c +++ b/tests/gsm23236/gsm23236_test.c @@ -138,7 +138,7 @@ struct nri_v_get_set_test nri_v_get_set_tests[] = { }, }; -void test_nri_v_get_set() +void test_nri_v_get_set(void) { struct nri_v_get_set_test *t; @@ -222,7 +222,7 @@ struct nri_validate_tc nri_validate_tests[] = { { .nri = INT16_MAX, .nri_bitlen = 0, .expect_rc = 1 }, }; -void test_nri_validate() +void test_nri_validate(void) { struct nri_validate_tc *t; printf("\n%s()\n", __func__); @@ -327,7 +327,7 @@ struct nri_range_validate_tc nri_range_validate_tests[] = { }; -void test_nri_range_validate() +void test_nri_range_validate(void) { struct nri_range_validate_tc *t; printf("\n%s()\n", __func__); @@ -357,7 +357,7 @@ void dump_list(const struct osmo_nri_ranges *nri_ranges) printf("};\n"); } -void test_nri_list() +void test_nri_list(void) { struct osmo_nri_ranges *nri_ranges = osmo_nri_ranges_alloc(ctx); printf("\n%s()\n", __func__); @@ -545,7 +545,7 @@ void test_nri_list() DEL(100, 1); } -void test_nri_limit_by_ranges() +void test_nri_limit_by_ranges(void) { const uint8_t nri_bitlen = 8; const int16_t expect_nri_vals[] = { 10, 20, 21, 30, 31, 32 }; @@ -594,7 +594,7 @@ void test_nri_limit_by_ranges() } } -int main() +int main(int argc, char **argv) { ctx = talloc_named_const(NULL, 0, "nri_test"); diff --git a/tests/gsm29205/gsm29205_test.c b/tests/gsm29205/gsm29205_test.c index 5d4835b7..6598f894 100644 --- a/tests/gsm29205/gsm29205_test.c +++ b/tests/gsm29205/gsm29205_test.c @@ -28,7 +28,7 @@ #include <string.h> #include <errno.h> -static void test_gcr() +static void test_gcr(void) { static const uint8_t res[] = { 0x03, /* .net_len */ diff --git a/tests/gsm48/rest_octets_test.c b/tests/gsm48/rest_octets_test.c index fdab1432..bf53212e 100644 --- a/tests/gsm48/rest_octets_test.c +++ b/tests/gsm48/rest_octets_test.c @@ -77,7 +77,7 @@ static const struct si13_test test_si13_arr[] = { }, }; -static void test_si13() +static void test_si13(void) { int i, rc; uint8_t data[GSM_MACBLOCK_LEN]; diff --git a/tests/lapd/lapd_test.c b/tests/lapd/lapd_test.c index ab0f3160..739f9b7d 100644 --- a/tests/lapd/lapd_test.c +++ b/tests/lapd/lapd_test.c @@ -376,7 +376,7 @@ static int ms_to_bts_tx_cb(struct msgb *msg, struct lapdm_entity *le, void *_ctx return 0; } -static void test_lapdm_polling() +static void test_lapdm_polling(void) { printf("I do some very simple LAPDm test.\n"); @@ -470,7 +470,7 @@ static void test_lapdm_polling() lapdm_channel_exit(&ms_to_bts_channel); } -static void test_lapdm_contention_resolution() +static void test_lapdm_contention_resolution(void) { printf("I test contention resultion by having two mobiles collide and " "first mobile repeating SABM.\n"); @@ -523,7 +523,7 @@ static void test_lapdm_contention_resolution() lapdm_channel_exit(&bts_to_ms_channel); } -static void test_lapdm_early_release() +static void test_lapdm_early_release(void) { printf("I test RF channel release of an unestablished channel.\n"); @@ -603,7 +603,7 @@ static void lapdm_establish(const uint8_t *est_req, size_t est_req_size) msgb_free(msg); } -static void test_lapdm_establishment() +static void test_lapdm_establishment(void) { printf("I test RF channel establishment.\n"); printf("Testing SAPI3/SDCCH\n"); @@ -677,7 +677,7 @@ static void dump_queue(struct llist_head *head) printf("\n"); } -static void test_lapdm_desync() +static void test_lapdm_desync(void) { printf("I test if desync problems exist in LAPDm\n"); diff --git a/tests/logging/logging_vty_test.c b/tests/logging/logging_vty_test.c index f67746b2..96b316db 100644 --- a/tests/logging/logging_vty_test.c +++ b/tests/logging/logging_vty_test.c @@ -78,7 +78,7 @@ DEFUN(log_sweep, log_sweep_cmd, return CMD_SUCCESS; } -static void vty_commands_init() +static void vty_commands_init(void) { install_element_ve(&log_sweep_cmd); } @@ -121,7 +121,7 @@ const struct log_info log_info = { .num_cat = ARRAY_SIZE(default_categories), }; -static void print_help() +static void print_help(void) { printf( "options:\n" " -h --help this text\n" diff --git a/tests/msgb/msgb_test.c b/tests/msgb/msgb_test.c index bd52f9f3..7966103b 100644 --- a/tests/msgb/msgb_test.c +++ b/tests/msgb/msgb_test.c @@ -61,7 +61,7 @@ static int osmo_panic_try(volatile int *exception, int setjmp_result) return *exception == 0; } -static void test_msgb_api() +static void test_msgb_api(void) { struct msgb *msg = msgb_alloc_headroom(4096, 128, "data"); unsigned char *cptr = NULL; @@ -117,7 +117,7 @@ static void test_msgb_api() msgb_free(msg); } -static void test_msgb_api_errors() +static void test_msgb_api_errors(void) { struct msgb *msg = msgb_alloc_headroom(4096, 128, "data"); volatile int e = 0; @@ -138,7 +138,7 @@ static void test_msgb_api_errors() osmo_set_panic_handler(NULL); } -static void test_msgb_copy() +static void test_msgb_copy(void) { struct msgb *msg = msgb_alloc_headroom(4096, 128, "data"); struct msgb *msg2; @@ -185,7 +185,7 @@ static void test_msgb_copy() msgb_free(msg2); } -static void test_msgb_resize_area() +static void test_msgb_resize_area(void) { struct msgb *msg = msgb_alloc_headroom(4096, 128, "data"); int rc; @@ -285,7 +285,7 @@ static void test_msgb_resize_area() osmo_set_panic_handler(NULL); } -static void test_msgb_printf() +static void test_msgb_printf(void) { struct msgb *msg; struct msgb *msg_ref; diff --git a/tests/sms/sms_test.c b/tests/sms/sms_test.c index 9ca83a55..912c0829 100644 --- a/tests/sms/sms_test.c +++ b/tests/sms/sms_test.c @@ -215,7 +215,7 @@ static const struct test_case test_decode[] = }, }; -static void test_octet_return() +static void test_octet_return(void) { char out[256]; int oct, septets; diff --git a/tests/smscb/cbsp_test.c b/tests/smscb/cbsp_test.c index d530798d..2dbdded7 100644 --- a/tests/smscb/cbsp_test.c +++ b/tests/smscb/cbsp_test.c @@ -81,7 +81,7 @@ static struct msgb *msgb_from_hex(unsigned int size, const char *hex) return msg; } -static void test_decode() +static void test_decode(void) { struct msgb *msg; struct osmo_cbsp_decoded *cbsp_dec; diff --git a/tests/sockaddr_str/sockaddr_str_test.c b/tests/sockaddr_str/sockaddr_str_test.c index 0d0674b6..541c3a15 100644 --- a/tests/sockaddr_str/sockaddr_str_test.c +++ b/tests/sockaddr_str/sockaddr_str_test.c @@ -90,7 +90,7 @@ void dump_oip(const struct osmo_sockaddr_str *oip) printf("{ .af = %s, .ip = %s, .port = %u }\n", af_name(oip->af), osmo_quote_str(oip->ip, -1), oip->port); } -void sockaddr_str_test_conversions() +void sockaddr_str_test_conversions(void) { int i; char buf[1024]; @@ -235,7 +235,7 @@ void sockaddr_str_test_conversions() } -static void test_osmo_sockaddr_str_cmp() +static void test_osmo_sockaddr_str_cmp(void) { int i; printf("\n\n%s\n", __func__); diff --git a/tests/socket/socket_test.c b/tests/socket/socket_test.c index fe77b92e..d090fba2 100644 --- a/tests/socket/socket_test.c +++ b/tests/socket/socket_test.c @@ -150,7 +150,7 @@ static int test_sockinit2(void) return 0; } -static int test_get_ip_and_port() +static int test_get_ip_and_port(void) { int fd, rc; char ip[INET6_ADDRSTRLEN] = { }; diff --git a/tests/stats/stats_test.c b/tests/stats/stats_test.c index 4e362234..2796100d 100644 --- a/tests/stats/stats_test.c +++ b/tests/stats/stats_test.c @@ -340,7 +340,7 @@ static void _do_report(int expect_counter_vals, int expect_stat_item_vals, int l #define do_report(A, B) _do_report(A, B, __LINE__) -static void test_reporting() +static void test_reporting(void) { struct osmo_stats_reporter *srep1, *srep2, *srep; struct osmo_stat_item_group *statg1, *statg2; diff --git a/tests/tdef/tdef_test.c b/tests/tdef/tdef_test.c index c348e694..a0fcc9a9 100644 --- a/tests/tdef/tdef_test.c +++ b/tests/tdef/tdef_test.c @@ -125,7 +125,7 @@ static void test_tdef_get(bool test_range) } } -static void test_tdef_get_nonexisting() +static void test_tdef_get_nonexisting(void) { printf("\n%s()\n", __func__); @@ -136,7 +136,7 @@ static void test_tdef_get_nonexisting() print_tdef_get(tdefs, 5, OSMO_TDEF_US); } -static void test_tdef_set_and_get() +static void test_tdef_set_and_get(void) { struct osmo_tdef *t; printf("\n%s()\n", __func__); @@ -317,7 +317,7 @@ const struct timeval fake_time_start_time = { 123, 456 }; osmo_timers_update(); \ } while (0) -void fake_time_start() +void fake_time_start(void) { struct timespec *clock_override; diff --git a/tests/tdef/tdef_vty_config_root_test.c b/tests/tdef/tdef_vty_config_root_test.c index aa5ff1b6..e2dbcb4c 100644 --- a/tests/tdef/tdef_vty_config_root_test.c +++ b/tests/tdef/tdef_vty_config_root_test.c @@ -111,7 +111,7 @@ static int config_write_timer(struct vty *vty) return CMD_SUCCESS; } -static void timer_init_vty() +static void timer_init_vty(void) { /* Again, this is merely to get a vty write hook, see above. */ install_node(&timer_node, config_write_timer); @@ -123,7 +123,7 @@ static void timer_init_vty() void *root_ctx = NULL; -static void print_help() +static void print_help(void) { printf( "options:\n" " -h --help this text\n" diff --git a/tests/tdef/tdef_vty_config_subnode_test.c b/tests/tdef/tdef_vty_config_subnode_test.c index 90c79682..d4abe096 100644 --- a/tests/tdef/tdef_vty_config_subnode_test.c +++ b/tests/tdef/tdef_vty_config_subnode_test.c @@ -102,7 +102,7 @@ static int config_write_gsmnet(struct vty *vty) return CMD_SUCCESS; } -static void gsmnet_init_vty() +static void gsmnet_init_vty(void) { install_node(&gsmnet_node, config_write_gsmnet); install_element(CONFIG_NODE, &cfg_net_cmd); @@ -116,7 +116,7 @@ static void gsmnet_init_vty() void *root_ctx = NULL; -static void print_help() +static void print_help(void) { printf( "options:\n" " -h --help this text\n" diff --git a/tests/tdef/tdef_vty_dynamic_test.c b/tests/tdef/tdef_vty_dynamic_test.c index a181d91b..715fa601 100644 --- a/tests/tdef/tdef_vty_dynamic_test.c +++ b/tests/tdef/tdef_vty_dynamic_test.c @@ -179,7 +179,7 @@ static int config_write_member(struct vty *vty) return CMD_SUCCESS; } -static void member_init_vty() +static void member_init_vty(void) { install_node(&member_node, config_write_member); install_element(CONFIG_NODE, &cfg_member_cmd); @@ -190,7 +190,7 @@ static void member_init_vty() /* ------------------- THE REST is just boilerplate osmo main() ------------------- */ -static void print_help() +static void print_help(void) { printf( "options:\n" " -h --help this text\n" diff --git a/tests/time_cc/time_cc_test.c b/tests/time_cc/time_cc_test.c index 22ea7f65..e4a5aaf3 100644 --- a/tests/time_cc/time_cc_test.c +++ b/tests/time_cc/time_cc_test.c @@ -125,7 +125,7 @@ static const struct log_info log_info = { .num_cat = ARRAY_SIZE(log_categories), }; -int main() +int main(int argc, char **argv) { void *ctx = talloc_named_const(NULL, 0, "time_cc_test"); struct timespec *now; diff --git a/tests/tlv/tlv_test.c b/tests/tlv/tlv_test.c index fdd15ab0..f9137ad3 100644 --- a/tests/tlv/tlv_test.c +++ b/tests/tlv/tlv_test.c @@ -188,7 +188,7 @@ static void check_lv_shift_data_len(size_t data_len, } } -static void test_tlv_shift_functions() +static void test_tlv_shift_functions(void) { uint8_t test_data[1024]; uint8_t buf[1024]; @@ -250,7 +250,7 @@ static void test_tlv_shift_functions() /* Most GSM related protocols clearly indicate that in case of duplicate * IEs, only the first occurrence shall be used, while any further occurrences * shall be ignored. See e.g. 3GPP TS 24.008 Section 8.6.3 */ -static void test_tlv_repeated_ie() +static void test_tlv_repeated_ie(void) { uint8_t test_data[768]; int i, rc; @@ -288,7 +288,7 @@ static void test_tlv_repeated_ie() OSMO_ASSERT(dec3[2].lv[tag].val == &test_data[2 + 3 + 3]); } -static void test_tlv_encoder() +static void test_tlv_encoder(void) { const uint8_t enc_ies[] = { 0x17, 0x14, 0x06, 0x2b, 0x12, 0x2b, 0x0b, 0x40, 0x2b, 0xb7, 0x05, 0xd0, 0x63, 0x82, 0x95, 0x03, 0x05, 0x40, @@ -332,7 +332,7 @@ static void test_tlv_encoder() msgb_free(msg); } -static void test_tlv_parser_bounds() +static void test_tlv_parser_bounds(void) { struct tlv_definition tdef; struct tlv_parsed dec; @@ -423,7 +423,7 @@ static void test_tlv_parser_bounds() OSMO_ASSERT(TLVP_VAL(&dec, 0x23) == NULL); } -static void test_tlv_lens() +static void test_tlv_lens(void) { uint16_t buf_len; uint8_t buf[512]; diff --git a/tests/use_count/use_count_test.c b/tests/use_count/use_count_test.c index 2942c697..b784aeb4 100644 --- a/tests/use_count/use_count_test.c +++ b/tests/use_count/use_count_test.c @@ -192,7 +192,7 @@ static struct foo *foo_alloc(const char *name, size_t static_entries) return foo; } -void print_foos() +void print_foos(void) { int count = 0; struct foo *foo; @@ -204,7 +204,7 @@ void print_foos() fprintf(stderr, "%d foos\n\n", count); } -static void test_use_count_fsm() +static void test_use_count_fsm(void) { struct foo *a, *b, *c; log("\n%s()\n", __func__); diff --git a/tests/utils/utils_test.c b/tests/utils/utils_test.c index 3ac5d1e5..9ddae651 100644 --- a/tests/utils/utils_test.c +++ b/tests/utils/utils_test.c @@ -342,7 +342,7 @@ static struct { { "DeafBeddedBabeAcceededFadedDecaff", 32, 32, false, false }, }; -bool test_is_hexstr() +bool test_is_hexstr(void) { int i; bool pass = true; @@ -1023,7 +1023,7 @@ struct osmo_str_tolowupper_test_data osmo_str_tolowupper_tests[] = { }; -static void osmo_str_tolowupper_test() +static void osmo_str_tolowupper_test(void) { int i; char buf[128]; @@ -1197,7 +1197,7 @@ int strbuf_cascade(char *buf, size_t buflen) return sb.chars_needed; } -void strbuf_test() +void strbuf_test(void) { char buf[256]; int rc; @@ -1230,7 +1230,7 @@ void strbuf_test() printf("(need %d chars, had size=63) %s\n", rc, buf); } -void strbuf_test_nolen() +void strbuf_test_nolen(void) { char buf[20]; struct osmo_strbuf sb = { .buf = buf, .len = sizeof(buf) }; @@ -1256,7 +1256,7 @@ static void startswith_test_str(const char *str, const char *startswith_str, boo printf(" ERROR: EXPECTED %s\n", expect_rc ? "true" : "false"); } -static void startswith_test() +static void startswith_test(void) { printf("\n%s()\n", __func__); startswith_test_str(NULL, NULL, true); @@ -1301,7 +1301,7 @@ static char *foo_name_c_zero_null(void *ctx, const char *arg) OSMO_NAME_C_IMPL(ctx, 0, NULL, foo_name_buf, arg) } -static void name_c_impl_test() +static void name_c_impl_test(void) { char *test_strs[] = { "test", @@ -1703,7 +1703,7 @@ const char *errno_str(int rc) return ""; } } -void test_float_str_to_int() +void test_float_str_to_int(void) { const struct float_str_to_int_test *t; printf("--- %s\n", __func__); @@ -1865,7 +1865,7 @@ struct int_to_float_str_test int_to_float_str_tests[] = { { 23, -9223372036854775807, "-0.00009223372036854775807" }, { 23, INT64_MIN, "-ERR" }, }; -void test_int_to_float_str() +void test_int_to_float_str(void) { const struct int_to_float_str_test *t; printf("--- %s\n", __func__); @@ -1956,7 +1956,7 @@ struct str_to_int_test str_to_int_tests[] = { { "123 ", 10, -1000, 1000, -E2BIG, 123 }, { "123.4", 10, -1000, 1000, -E2BIG, 123 }, }; -void test_str_to_int() +void test_str_to_int(void) { const struct str_to_int_test *t; printf("--- %s\n", __func__); @@ -2053,7 +2053,7 @@ struct str_to_int64_test str_to_int64_tests[] = { { "-9223372036854775809", 10, -1000, 1000, -EOVERFLOW, INT64_MIN }, { "9223372036854775808", 10, -1000, 1000, -EOVERFLOW, INT64_MAX }, }; -void test_str_to_int64() +void test_str_to_int64(void) { const struct str_to_int64_test *t; printf("--- %s\n", __func__); diff --git a/tests/vty/vty_test.c b/tests/vty/vty_test.c index 3076a703..01e323ed 100644 --- a/tests/vty/vty_test.c +++ b/tests/vty/vty_test.c @@ -476,7 +476,7 @@ DEFUN(cfg_range_baseboth, cfg_range_baseboth_cmd, return CMD_SUCCESS; } -void test_vty_add_cmds() +void test_vty_add_cmds(void) { install_element(CONFIG_NODE, &cfg_ret_warning_cmd); install_element(CONFIG_NODE, &cfg_ret_success_cmd); @@ -507,7 +507,7 @@ void test_vty_add_cmds() install_element_ve(&cfg_range_baseboth_cmd); } -void test_is_cmd_ambiguous() +void test_is_cmd_ambiguous(void) { struct vty *vty; struct vty_test test; @@ -526,7 +526,7 @@ void test_is_cmd_ambiguous() destroy_test_vty(&test, vty); } -void test_numeric_range() +void test_numeric_range(void) { struct vty *vty; struct vty_test test; @@ -541,7 +541,7 @@ void test_numeric_range() destroy_test_vty(&test, vty); } -void test_ranges() +void test_ranges(void) { struct vty *vty; struct vty_test test; diff --git a/tests/vty/vty_transcript_test.c b/tests/vty/vty_transcript_test.c index 84664f92..0f18f7eb 100644 --- a/tests/vty/vty_transcript_test.c +++ b/tests/vty/vty_transcript_test.c @@ -37,7 +37,7 @@ void *root_ctx = NULL; -static void print_help() +static void print_help(void) { printf( "options:\n" " -h --help this text\n" @@ -315,7 +315,7 @@ DEFUN_ATTR_USRATTR(cfg_attr_hidden_app_attr_unbelievable, return CMD_SUCCESS; } -static void init_vty_cmds() +static void init_vty_cmds(void) { install_element_ve(&single0_cmd); install_element_ve(&multi0_cmd); diff --git a/utils/osmo-aka-verify.c b/utils/osmo-aka-verify.c index bbc65ef7..f23c349b 100644 --- a/utils/osmo-aka-verify.c +++ b/utils/osmo-aka-verify.c @@ -88,7 +88,7 @@ static int milenage_check(const uint8_t *opc, const uint8_t *k, const uint8_t *s } -static void help() +static void help(void) { printf( "Static SIM card parameters:\n" "-k --key\tSpecify Ki / K\n" diff --git a/utils/osmo-auc-gen.c b/utils/osmo-auc-gen.c index 72f1fcd4..e3e1b431 100644 --- a/utils/osmo-auc-gen.c +++ b/utils/osmo-auc-gen.c @@ -85,7 +85,7 @@ static struct osmo_sub_auth_data test_aud = { .algo = OSMO_AUTH_ALG_NONE, }; -static void help() +static void help(void) { int alg; printf( "-2 --2g\tUse 2G (GSM) authentication\n" diff --git a/utils/osmo-ns-dummy.c b/utils/osmo-ns-dummy.c index 0af1a897..eabe0085 100644 --- a/utils/osmo-ns-dummy.c +++ b/utils/osmo-ns-dummy.c @@ -43,7 +43,7 @@ static struct vty_app_info vty_info = { .copyright = vty_copyright, }; -static void print_help() +static void print_help(void) { printf( "Some useful options:\n" " -h --help This text\n" |