Let OBUs check CAMs

This commit is contained in:
emanuel 2020-11-30 20:05:24 +00:00
parent 18ae6f1182
commit 1da612443b
2 changed files with 9 additions and 4 deletions

View File

@ -193,7 +193,14 @@ int itss_config(void* facilities_s, char* config_file) {
fseek(fp, 0, SEEK_END);
uint16_t size = ftell(fp);
fseek(fp, 0, SEEK_SET);
if (!fread(pz_xml, 1, size, fp)) continue;
if (!size) {
fclose(fp);
continue;
}
if (!fread(pz_xml, 1, size, fp)) {
fclose(fp);
continue;
}
fclose(fp);
ProtectedCommunicationZone_t *zone = calloc(1, sizeof(ProtectedCommunicationZone_t));

View File

@ -84,9 +84,7 @@ static int transport_indication(facilities_t *facilities, void* responder, uint8
switch (bdi->destinationPort) {
case Port_cam:
if (facilities->station_type == 15) { // Currently only RSUs need to check CAMs
check_cam(facilities, bdi, its_msg);
}
check_cam(facilities, bdi, its_msg);
break;
case Port_denm: