Fixing a few last cppcheck errors/warnings
Signed-off-by: Raphael Defosseux <raphael.defosseux@eurecom.fr>
This commit is contained in:
@@ -46,7 +46,7 @@ void unregister_notifier(gui *_g, unsigned long notifier_id) {
|
||||
if (g->notifiers[i].id == notifier_id) break;
|
||||
|
||||
if (i == g->notifiers_count)
|
||||
ERR("%s:%d: notifier_id %ld not found\n", __FILE__,__LINE__,notifier_id);
|
||||
ERR("%s:%d: notifier_id %lu not found\n", __FILE__,__LINE__,notifier_id);
|
||||
|
||||
free(g->notifiers[i].notification);
|
||||
memmove(g->notifiers + i, g->notifiers + i + 1,
|
||||
|
||||
@@ -261,6 +261,7 @@ int main(int n, char **v)
|
||||
if (fds == NULL) { perror("calloc"); exit(1); }
|
||||
}
|
||||
i = 0;
|
||||
if (fds == NULL) { perror("null fds pointer"); exit(1); }
|
||||
fds[i].fd = l;
|
||||
fds[i].events = POLLIN;
|
||||
i++;
|
||||
|
||||
@@ -195,5 +195,10 @@ int main(int n, char **v)
|
||||
handle_event(h, e);
|
||||
}
|
||||
|
||||
if (on_off_name != NULL)
|
||||
free(on_off_name);
|
||||
if (on_off_action != NULL)
|
||||
free(on_off_action);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -273,6 +273,6 @@ void PUTX2(OBUF *o, int i) {
|
||||
|
||||
void PUTUL(OBUF *o, unsigned long l) {
|
||||
char s[128];
|
||||
sprintf(s, "%ld", l);
|
||||
sprintf(s, "%lu", l);
|
||||
PUTS(o, s);
|
||||
}
|
||||
|
||||
@@ -812,9 +812,6 @@ void phy_scope_UE(FD_lte_phy_scope_ue *form,
|
||||
free(bit1);
|
||||
free(bit_pdcch);
|
||||
free(llr_pdcch);
|
||||
for (arx=0;arx<nb_antennas_rx;arx++) {
|
||||
free(chest_t_abs[arx]);
|
||||
}
|
||||
|
||||
//This is done to avoid plotting old data when TB0 is disabled, and TB1 is mapped onto CW0
|
||||
/*if (phy_vars_ue->transmission_mode[eNB_id]==3 && phy_vars_ue->transmission_mode[eNB_id]==4){
|
||||
|
||||
@@ -107,7 +107,7 @@ int s1ap_eNB_handle_trace_start(uint32_t assoc_id,
|
||||
{
|
||||
S1AP_TraceStart_t *container;
|
||||
S1AP_TraceStartIEs_t *ie;
|
||||
struct s1ap_eNB_ue_context_s *ue_desc_p;
|
||||
struct s1ap_eNB_ue_context_s *ue_desc_p = NULL;
|
||||
struct s1ap_eNB_mme_data_s *mme_ref_p;
|
||||
|
||||
DevAssert(pdu != NULL);
|
||||
|
||||
@@ -270,7 +270,7 @@ static void enb_config_display(void)
|
||||
printf( " ENB CONFIG FILE CONTENT LOADED:\n");
|
||||
printf( "----------------------------------------------------------------------\n");
|
||||
for (i = 0; i < g_enb_properties.number; i++) {
|
||||
printf( "ENB CONFIG for instance %u:\n\n", i);
|
||||
printf( "ENB CONFIG for instance %d:\n\n", i);
|
||||
printf( "\teNB name: \t%s\n",g_enb_properties.properties[i]->eNB_name);
|
||||
printf( "\teNB ID: \t%"PRIu32"\n",g_enb_properties.properties[i]->eNB_id);
|
||||
printf( "\tCell type: \t%s\n",g_enb_properties.properties[i]->cell_type == CELL_MACRO_ENB ? "CELL_MACRO_ENB":"CELL_HOME_ENB");
|
||||
|
||||
@@ -1103,7 +1103,7 @@ et_config_parse_opt_line (
|
||||
fprintf(stderr, "Please provide a valid -D/--delay-on-exit argument, %s is not a valid value\n", delay_on_exit);
|
||||
exit(1);
|
||||
}
|
||||
printf("Delay on exit is %u\n", delay_on_exit);
|
||||
printf("Delay on exit is %d\n", (int) delay_on_exit);
|
||||
}
|
||||
break;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user