diff options
author | Donald Sharp <donaldsharp72@gmail.com> | 2022-10-26 02:04:43 +0200 |
---|---|---|
committer | Donald Sharp <donaldsharp72@gmail.com> | 2022-10-26 02:04:43 +0200 |
commit | 2816045a6edf64db6c5018db54a33aa4f66fca58 (patch) | |
tree | 409968bd084745d4acad15342321ebabd360be6f | |
parent | Merge pull request #12151 from louis-6wind/fix-mpls-te (diff) | |
download | frr-2816045a6edf64db6c5018db54a33aa4f66fca58.tar.xz frr-2816045a6edf64db6c5018db54a33aa4f66fca58.zip |
pceplib: Fix clang-16 not happy with build
In this case it was functions without a prototype
Signed-off-by: Donald Sharp <donaldsharp72@gmail.com>
-rw-r--r-- | pceplib/pcep_msg_messages.c | 2 | ||||
-rw-r--r-- | pceplib/pcep_msg_messages_encoding.c | 2 | ||||
-rw-r--r-- | pceplib/pcep_pcc.c | 4 | ||||
-rw-r--r-- | pceplib/pcep_pcc_api.c | 14 | ||||
-rw-r--r-- | pceplib/pcep_session_logic.c | 6 | ||||
-rw-r--r-- | pceplib/pcep_socket_comm.c | 6 | ||||
-rw-r--r-- | pceplib/pcep_timers.c | 4 | ||||
-rw-r--r-- | pceplib/pcep_utils_double_linked_list.c | 2 | ||||
-rw-r--r-- | pceplib/pcep_utils_logging.c | 2 | ||||
-rw-r--r-- | pceplib/pcep_utils_memory.c | 4 | ||||
-rw-r--r-- | pceplib/pcep_utils_queue.c | 2 |
11 files changed, 23 insertions, 25 deletions
diff --git a/pceplib/pcep_msg_messages.c b/pceplib/pcep_msg_messages.c index 9bbfc5372..5a244098d 100644 --- a/pceplib/pcep_msg_messages.c +++ b/pceplib/pcep_msg_messages.c @@ -163,7 +163,7 @@ pcep_msg_create_error_with_objects(uint8_t error_type, uint8_t error_value, return message; } -struct pcep_message *pcep_msg_create_keepalive() +struct pcep_message *pcep_msg_create_keepalive(void) { return (pcep_msg_create_common(PCEP_TYPE_KEEPALIVE)); } diff --git a/pceplib/pcep_msg_messages_encoding.c b/pceplib/pcep_msg_messages_encoding.c index e90ca1cfd..2d27e4040 100644 --- a/pceplib/pcep_msg_messages_encoding.c +++ b/pceplib/pcep_msg_messages_encoding.c @@ -348,7 +348,7 @@ struct pcep_message *pcep_decode_message(const uint8_t *msg_buf) return msg; } -struct pcep_versioning *create_default_pcep_versioning() +struct pcep_versioning *create_default_pcep_versioning(void) { struct pcep_versioning *versioning = pceplib_malloc(PCEPLIB_INFRA, sizeof(struct pcep_versioning)); diff --git a/pceplib/pcep_pcc.c b/pceplib/pcep_pcc.c index 18ccf250a..47e357729 100644 --- a/pceplib/pcep_pcc.c +++ b/pceplib/pcep_pcc.c @@ -74,7 +74,6 @@ static const short DEFAULT_SRC_TCP_PORT = 4999; // Private fn's struct cmd_line_args *get_cmdline_args(int argc, char *argv[]); void handle_signal_action(int sig_number); -int setup_signals(void); void send_pce_path_request_message(pcep_session *session); void send_pce_report_message(pcep_session *session); void print_queue_event(struct pcep_event *event); @@ -211,8 +210,7 @@ void handle_signal_action(int sig_number) } } - -int setup_signals() +static int setup_signals(void) { struct sigaction sa; memset(&sa, 0, sizeof(sa)); diff --git a/pceplib/pcep_pcc_api.c b/pceplib/pcep_pcc_api.c index b7813c5a0..75c2b59b6 100644 --- a/pceplib/pcep_pcc_api.c +++ b/pceplib/pcep_pcc_api.c @@ -55,7 +55,7 @@ const char UNKNOWN_EVENT_STR[] = "UNKNOWN Event Type"; /* Session Logic Handle managed in pcep_session_logic.c */ extern pcep_event_queue *session_logic_event_queue_; -bool initialize_pcc() +bool initialize_pcc(void) { if (!run_session_logic()) { pcep_log(LOG_ERR, "%s: Error initializing PCC session logic.", @@ -85,13 +85,13 @@ bool initialize_pcc_infra(struct pceplib_infra_config *infra_config) /* this function is blocking */ -bool initialize_pcc_wait_for_completion() +bool initialize_pcc_wait_for_completion(void) { return run_session_logic_wait_for_completion(); } -bool destroy_pcc() +bool destroy_pcc(void) { if (!stop_session_logic()) { pcep_log(LOG_WARNING, "%s: Error stopping PCC session logic.", @@ -103,7 +103,7 @@ bool destroy_pcc() } -pcep_configuration *create_default_pcep_configuration() +pcep_configuration *create_default_pcep_configuration(void) { pcep_configuration *config = pceplib_malloc(PCEPLIB_INFRA, sizeof(pcep_configuration)); @@ -226,7 +226,7 @@ void send_message(pcep_session *session, struct pcep_message *msg, } /* Returns true if the queue is empty, false otherwise */ -bool event_queue_is_empty() +bool event_queue_is_empty(void) { if (session_logic_event_queue_ == NULL) { pcep_log( @@ -246,7 +246,7 @@ bool event_queue_is_empty() /* Return the number of events on the queue, 0 if empty */ -uint32_t event_queue_num_events_available() +uint32_t event_queue_num_events_available(void) { if (session_logic_event_queue_ == NULL) { pcep_log( @@ -266,7 +266,7 @@ uint32_t event_queue_num_events_available() /* Return the next event on the queue, NULL if empty */ -struct pcep_event *event_queue_get_event() +struct pcep_event *event_queue_get_event(void) { if (session_logic_event_queue_ == NULL) { pcep_log( diff --git a/pceplib/pcep_session_logic.c b/pceplib/pcep_session_logic.c index 78d107255..02cf3bffb 100644 --- a/pceplib/pcep_session_logic.c +++ b/pceplib/pcep_session_logic.c @@ -111,7 +111,7 @@ static bool run_session_logic_common(void) } -bool run_session_logic() +bool run_session_logic(void) { if (!run_session_logic_common()) { return false; @@ -234,7 +234,7 @@ bool run_session_logic_with_infra(pceplib_infra_config *infra_config) return true; } -bool run_session_logic_wait_for_completion() +bool run_session_logic_wait_for_completion(void) { if (!run_session_logic()) { return false; @@ -247,7 +247,7 @@ bool run_session_logic_wait_for_completion() } -bool stop_session_logic() +bool stop_session_logic(void) { if (session_logic_handle_ == NULL) { pcep_log(LOG_WARNING, "%s: Session logic already stopped", diff --git a/pceplib/pcep_socket_comm.c b/pceplib/pcep_socket_comm.c index e22eb6e67..4a97c8489 100644 --- a/pceplib/pcep_socket_comm.c +++ b/pceplib/pcep_socket_comm.c @@ -62,7 +62,7 @@ int socket_fd_node_compare(void *list_entry, void *new_entry) } -bool initialize_socket_comm_pre() +bool initialize_socket_comm_pre(void) { socket_comm_handle_ = pceplib_malloc(PCEPLIB_INFRA, sizeof(pcep_socket_comm_handle)); @@ -129,7 +129,7 @@ bool initialize_socket_comm_external_infra( return true; } -bool initialize_socket_comm_loop() +bool initialize_socket_comm_loop(void) { if (socket_comm_handle_ != NULL) { /* already initialized */ @@ -152,7 +152,7 @@ bool initialize_socket_comm_loop() } -bool destroy_socket_comm_loop() +bool destroy_socket_comm_loop(void) { socket_comm_handle_->active = false; diff --git a/pceplib/pcep_timers.c b/pceplib/pcep_timers.c index b0f3e70b5..61fda1636 100644 --- a/pceplib/pcep_timers.c +++ b/pceplib/pcep_timers.c @@ -197,7 +197,7 @@ void free_all_timers(pcep_timers_context *timers_context) } -bool teardown_timers() +bool teardown_timers(void) { if (timers_context_ == NULL) { pcep_log( @@ -252,7 +252,7 @@ bool teardown_timers() } -int get_next_timer_id() +int get_next_timer_id(void) { if (timer_id_ == INT_MAX) { timer_id_ = 0; diff --git a/pceplib/pcep_utils_double_linked_list.c b/pceplib/pcep_utils_double_linked_list.c index 696e46632..7f90df40f 100644 --- a/pceplib/pcep_utils_double_linked_list.c +++ b/pceplib/pcep_utils_double_linked_list.c @@ -31,7 +31,7 @@ #include "pcep_utils_logging.h" #include "pcep_utils_memory.h" -double_linked_list *dll_initialize() +double_linked_list *dll_initialize(void) { double_linked_list *handle = pceplib_malloc(PCEPLIB_INFRA, sizeof(double_linked_list)); diff --git a/pceplib/pcep_utils_logging.c b/pceplib/pcep_utils_logging.c index 0286c2307..c9b2588b4 100644 --- a/pceplib/pcep_utils_logging.c +++ b/pceplib/pcep_utils_logging.c @@ -45,7 +45,7 @@ void set_logging_level(int level) logging_level_ = level; } -int get_logging_level() +int get_logging_level(void) { return logging_level_; } diff --git a/pceplib/pcep_utils_memory.c b/pceplib/pcep_utils_memory.c index c564705f6..10856cac2 100644 --- a/pceplib/pcep_utils_memory.c +++ b/pceplib/pcep_utils_memory.c @@ -75,7 +75,7 @@ bool pceplib_memory_initialize(void *pceplib_infra_mt, return true; } -void pceplib_memory_reset() +void pceplib_memory_reset(void) { pceplib_infra_mt.total_bytes_allocated = 0; pceplib_infra_mt.num_allocates = 0; @@ -88,7 +88,7 @@ void pceplib_memory_reset() pceplib_messages_mt.num_frees = 0; } -void pceplib_memory_dump() +void pceplib_memory_dump(void) { if (PCEPLIB_INFRA) { pcep_log( diff --git a/pceplib/pcep_utils_queue.c b/pceplib/pcep_utils_queue.c index 627533d01..22e417111 100644 --- a/pceplib/pcep_utils_queue.c +++ b/pceplib/pcep_utils_queue.c @@ -33,7 +33,7 @@ #include "pcep_utils_memory.h" #include "pcep_utils_queue.h" -queue_handle *queue_initialize() +queue_handle *queue_initialize(void) { /* Set the max_entries to 0 to disable it */ return queue_initialize_with_size(0); |