mirror of
https://gitea.osmocom.org/cellular-infrastructure/osmo-mgw.git
synced 2025-10-23 08:12:01 +00:00
mgcp_endp: use NUM_E1_TS from e1_input.h
do not introduce another define constant, use NUM_E1_TS as number of E1 timeslots. Change-Id: I3bbfb6822d5595f9d243849141883490fa8037cb
This commit is contained in:
@@ -27,9 +27,9 @@
|
||||
#include <osmocom/mgcp/mgcp_endp.h>
|
||||
#include <osmocom/mgcp/mgcp_trunk.h>
|
||||
|
||||
#include <osmocom/abis/e1_input.h>
|
||||
#include <osmocom/mgcp/mgcp_e1.h>
|
||||
|
||||
#define E1_TIMESLOTS 32
|
||||
#define E1_RATE_MAX 64
|
||||
#define E1_OFFS_MAX 8
|
||||
|
||||
@@ -375,7 +375,7 @@ static uint8_t e1_ts_nr_from_epname(const char *epname)
|
||||
if (strncmp(token, "s-", 2) == 0) {
|
||||
errno = 0;
|
||||
res = strtoul(token + 2, NULL, 10);
|
||||
if (errno == ERANGE || res > E1_TIMESLOTS)
|
||||
if (errno == ERANGE || res > NUM_E1_TS)
|
||||
return 0xff;
|
||||
return (uint8_t) res;
|
||||
}
|
||||
|
Reference in New Issue
Block a user