Merge branch 'develop' into develop-nr
This commit is contained in:
Executable → Regular
@@ -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");
|
||||
@@ -353,7 +353,7 @@ void enb_config_init(const char const * lib_config_file_name_pP)
|
||||
setting_enb = config_setting_get_elem(setting, i);
|
||||
active_enb[i] = config_setting_get_string (setting_enb);
|
||||
AssertFatal (active_enb[i] != NULL,
|
||||
"Failed to parse config file %s, %uth attribute %s \n",
|
||||
"Failed to parse config file %s, %dth attribute %s \n",
|
||||
lib_config_file_name_pP, i, ENB_CONFIG_STRING_ACTIVE_ENBS);
|
||||
active_enb[i] = strdup(active_enb[i]);
|
||||
num_enb_properties += 1;
|
||||
@@ -393,7 +393,7 @@ void enb_config_init(const char const * lib_config_file_name_pP)
|
||||
)
|
||||
) {
|
||||
AssertError (0, parse_errors ++,
|
||||
"Failed to parse eNB configuration file %s, %u th enb\n",
|
||||
"Failed to parse eNB configuration file %s, %d th enb\n",
|
||||
lib_config_file_name_pP, i);
|
||||
continue; // FIXME this prevents segfaults below, not sure what happens after function exit
|
||||
}
|
||||
@@ -441,7 +441,7 @@ void enb_config_init(const char const * lib_config_file_name_pP)
|
||||
)
|
||||
) {
|
||||
AssertError (0, parse_errors ++,
|
||||
"Failed to parse eNB configuration file %s, %u th enb %u th mme address !\n",
|
||||
"Failed to parse eNB configuration file %s, %d th enb %d th mme address !\n",
|
||||
lib_config_file_name_pP, i, j);
|
||||
continue; // FIXME will prevent segfaults below, not sure what happens at function exit...
|
||||
}
|
||||
|
||||
@@ -37,11 +37,7 @@
|
||||
#include "platform_types.h"
|
||||
#include "platform_constants.h"
|
||||
#include "s1ap_messages_types.h"
|
||||
#ifdef CMAKER
|
||||
#include "SystemInformationBlockType2.h"
|
||||
#else
|
||||
#include "RRC/LTE/MESSAGES/SystemInformationBlockType2.h"
|
||||
#endif
|
||||
|
||||
#define IPV4_STR_ADDR_TO_INT_NWBO(AdDr_StR,NwBo,MeSsAgE ) do {\
|
||||
struct in_addr inp;\
|
||||
|
||||
@@ -249,7 +249,7 @@ int et_hex2data(unsigned char * const data, const unsigned char * const hexstrin
|
||||
char *endptr = NULL;
|
||||
size_t count = 0;
|
||||
|
||||
fprintf(stdout, "%s(%s,%d)\n", __FUNCTION__, hexstring, len);
|
||||
fprintf(stdout, "%s(%s,%u)\n", __FUNCTION__, hexstring, len);
|
||||
|
||||
if ((len > 1) && (strlen((const char*)hexstring) % 2)) {
|
||||
//or hexstring has an odd length
|
||||
@@ -473,7 +473,7 @@ void et_enb_config_init(const char const * lib_config_file_name_pP)
|
||||
setting_enb = config_setting_get_elem(setting, i);
|
||||
active_enb[i] = config_setting_get_string (setting_enb);
|
||||
AssertFatal (active_enb[i] != NULL,
|
||||
"Failed to parse config file %s, %uth attribute %s \n",
|
||||
"Failed to parse config file %s, %dth attribute %s \n",
|
||||
lib_config_file_name_pP, i, ENB_CONFIG_STRING_ACTIVE_ENBS);
|
||||
active_enb[i] = strdup(active_enb[i]);
|
||||
num_enb_properties += 1;
|
||||
@@ -513,7 +513,7 @@ void et_enb_config_init(const char const * lib_config_file_name_pP)
|
||||
)
|
||||
) {
|
||||
AssertError (0, parse_errors ++,
|
||||
"Failed to parse eNB configuration file %s, %u th enb\n",
|
||||
"Failed to parse eNB configuration file %s, %d th enb\n",
|
||||
lib_config_file_name_pP, i);
|
||||
continue; // FIXME this prevents segfaults below, not sure what happens after function exit
|
||||
}
|
||||
@@ -561,7 +561,7 @@ void et_enb_config_init(const char const * lib_config_file_name_pP)
|
||||
)
|
||||
) {
|
||||
AssertError (0, parse_errors ++,
|
||||
"Failed to parse eNB configuration file %s, %u th enb %u th mme address !\n",
|
||||
"Failed to parse eNB configuration file %s, %d th enb %d th mme address !\n",
|
||||
lib_config_file_name_pP, i, j);
|
||||
continue; // FIXME will prevent segfaults below, not sure what happens at function exit...
|
||||
}
|
||||
@@ -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 %d\n", delay_on_exit);
|
||||
printf("Delay on exit is %d\n", (int) delay_on_exit);
|
||||
}
|
||||
break;
|
||||
|
||||
|
||||
@@ -397,7 +397,7 @@ typedef struct et_event_s {
|
||||
} u;
|
||||
} et_event_t;
|
||||
|
||||
inline void et_free_pointer(void *p) {if (NULL != p) {free(p); p=NULL;}};
|
||||
inline void et_free_pointer(void *p) {if (NULL != p) {free(p);}};
|
||||
|
||||
//-------------------------
|
||||
void et_free_packet(et_packet_t *packet);
|
||||
|
||||
@@ -53,7 +53,7 @@ void et_print_hex_octets(const unsigned char *const byte_stream, const unsigned
|
||||
fprintf(stdout, " |\n");
|
||||
}
|
||||
|
||||
fprintf(stdout, " %04ld |", octet_index);
|
||||
fprintf(stdout, " %04lu |", octet_index);
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
@@ -94,7 +94,7 @@ void et_parse_s1ap(xmlDocPtr doc, const xmlNode const *s1ap_node, et_s1ap_t * co
|
||||
xml_char = xmlGetProp((xmlNode *)cur_node, (const xmlChar *)"value");
|
||||
if (NULL != xml_char) {
|
||||
xml_char2 = xmlGetProp((xmlNode *)cur_node, (const xmlChar *)"name");
|
||||
fprintf(stdout, "s1ap %p field name %s size %d value %s\n",s1ap, xml_char2, size, xml_char);
|
||||
fprintf(stdout, "s1ap %p field name %s size %u value %s\n",s1ap, xml_char2, size, xml_char);
|
||||
xmlFree(xml_char2);
|
||||
// if success to get value, do not parse children
|
||||
//AssertFatal ((xmlStrlen(xml_char) == size), "ERROR %s() mismatch in size %d and strlen %d\n", __FUNCTION__, size, xmlStrlen(xml_char));
|
||||
@@ -104,7 +104,7 @@ void et_parse_s1ap(xmlDocPtr doc, const xmlNode const *s1ap_node, et_s1ap_t * co
|
||||
rc = et_hex2data( &s1ap->binary_stream[s1ap->binary_stream_pos], xml_char, xmlStrlen(xml_char));
|
||||
s1ap->binary_stream_pos += xmlStrlen(xml_char)/2;
|
||||
//et_display_node(cur_node, 0);
|
||||
AssertFatal (rc >= 0, "ERROR in converting hex string %s len %d size %d rc %d\n", xml_char, xmlStrlen(xml_char), size, rc);
|
||||
AssertFatal (rc >= 0, "ERROR in converting hex string %s len %d size %u rc %d\n", xml_char, xmlStrlen(xml_char), size, rc);
|
||||
go_deeper_in_tree = 0;
|
||||
//}
|
||||
xmlFree(xml_char);
|
||||
|
||||
@@ -616,7 +616,7 @@ int et_scenario_set_packet_received(et_packet_t * const packet)
|
||||
|
||||
if (0 != packet->timer_id) {
|
||||
rc = timer_remove(packet->timer_id);
|
||||
AssertFatal(rc == 0, "TODO: Debug Timer on Rx packet num %d unknown", packet->packet_number);
|
||||
AssertFatal(rc == 0, "TODO: Debug Timer on Rx packet num %u unknown", packet->packet_number);
|
||||
g_scenario->timer_count--;
|
||||
return rc;
|
||||
}
|
||||
@@ -919,7 +919,7 @@ void et_s1ap_update_assoc_id_of_packets(const int32_t assoc_id,
|
||||
break;
|
||||
|
||||
default:
|
||||
AssertFatal(0, "Unknown chunk_type %d packet num %d", packet->sctp_hdr.chunk_type, packet->packet_number);
|
||||
AssertFatal(0, "Unknown chunk_type %d packet num %u", packet->sctp_hdr.chunk_type, packet->packet_number);
|
||||
;
|
||||
}
|
||||
packet = packet->next;
|
||||
|
||||
@@ -122,7 +122,7 @@ void update_xpath_node_mme_ue_s1ap_id(et_s1ap_t * const s1ap, xmlNode *node, con
|
||||
hex[2] = '\0';
|
||||
end_ptr = hex;
|
||||
uli = strtoul(hex, &end_ptr, 16);
|
||||
AssertFatal((uli != ULONG_MAX) && (end_ptr != NULL) && (*end_ptr == '\0'), "Conversion of hexstring %s failed returned %ld errno %d", hex, uli, errno);
|
||||
AssertFatal((uli != ULONG_MAX) && (end_ptr != NULL) && (*end_ptr == '\0'), "Conversion of hexstring %s failed returned %lu errno %d", hex, uli, errno);
|
||||
s1ap->binary_stream[pos++] = (unsigned char)uli;
|
||||
} while (pos2 < (2*5));
|
||||
// update ASN1
|
||||
|
||||
Reference in New Issue
Block a user