From 79135acbb88c92bbe0214ada4feea53cb12a0ef4 Mon Sep 17 00:00:00 2001 From: Michael McTernan Date: Fri, 4 Sep 2015 15:57:47 +0200 Subject: mgcp: Remove use of hardwired @mgw from endpoint IDs. Remove the host portion of the endpoint Id. This requires less configuration and we are probably fine to trust that MGCP only received messages designated for it. --- openbsc/src/libmgcp/mgcp_protocol.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openbsc/src/libmgcp/mgcp_protocol.c b/openbsc/src/libmgcp/mgcp_protocol.c index 717c1fc08..103897c7f 100644 --- a/openbsc/src/libmgcp/mgcp_protocol.c +++ b/openbsc/src/libmgcp/mgcp_protocol.c @@ -431,7 +431,7 @@ static struct mgcp_endpoint *find_endpoint(struct mgcp_config *cfg, const char * return find_e1_endpoint(cfg, mgcp); } else { gw = strtoul(mgcp, &endptr, 16); - if (gw > 0 && gw < cfg->trunk.number_endpoints && strcmp(endptr, "@mgw") == 0) + if (gw > 0 && gw < cfg->trunk.number_endpoints && endptr[0] == '@') return &cfg->trunk.endpoints[gw]; } -- cgit v1.2.3