fixed the encoding of the reservation response and added the rv to the evrsrm log

This commit is contained in:
gilteixeira 2023-04-23 16:11:35 +01:00
parent ad1d00f7c9
commit 1b75cb351c
1 changed files with 2 additions and 2 deletions

View File

@ -198,7 +198,7 @@ int evrsrm_recv(EV_RSR_t *evrsr_request) {
itss_queue_send(facilities.tx_queue, fi_oer, enc_fdi.encoded + 1, ITSS_APPLICATIONS, id, "FI.message");
cleanup:
log_debug("[ev] evrsrm_recv done");
log_debug("[ev] evrsrm_recv done with rv %d", rv);
return rv;
}
@ -243,7 +243,7 @@ static int evrsrm_reservation_response(EV_RSR_t *evrsrm_request, uint8_t *evrsrm
response->expirationTime = evrsrm_request->messageBody.choice.reservationRequestMessage.arrivalTime;
response->expirationTime += 15 * 60 * 1000; // 15 minutes
asn_enc_rval_t enc = oer_encode_to_buffer(&asn_DEF_EV_RSR, NULL, evrsr_response, evrsrm_oer, 512);
asn_enc_rval_t enc = uper_encode_to_buffer(&asn_DEF_EV_RSR, NULL, evrsr_response, evrsrm_oer, 512);
if (enc.encoded == -1) {
log_error("[ev] failed encoding evrsrm (%s)", enc.failed_type->name);
rv = 1;