rsl: Fix the audio handling after the 'alignment' handling fix
The issue got introduced in fcdba6bfac
when moving from the uint32_t pointer to a plain int. The code
was now like this:
if (connect_ip > 0) {
if (connect_ip == 0)
lookup_ip_based_on_rsl
...
Coverity detected this as logically dead code and it was breaking
audio handling for the osmo-bsc case. Remove the tristate handling,
the RSL behavior is that leaving out port/ip is like specifying it
as zero.
Fixes: Coverity CID 1040769
This commit is contained in:
parent
ed966f0428
commit
612f387fc9
|
@ -1252,6 +1252,7 @@ static int rsl_rx_ipac_XXcx(struct msgb *msg)
|
|||
uint16_t connect_port = 0;
|
||||
int rc, inc_ip_port = 0, port;
|
||||
char *name;
|
||||
struct in_addr ia;
|
||||
|
||||
if (dch->c.msg_type == RSL_MT_IPAC_CRCX)
|
||||
name = "CRCX";
|
||||
|
@ -1353,8 +1354,6 @@ static int rsl_rx_ipac_XXcx(struct msgb *msg)
|
|||
}
|
||||
}
|
||||
|
||||
if (connect_ip && connect_port) {
|
||||
struct in_addr ia;
|
||||
|
||||
/* Special rule: If connect_ip == 0.0.0.0, use RSL IP
|
||||
* address */
|
||||
|
@ -1380,10 +1379,6 @@ static int rsl_rx_ipac_XXcx(struct msgb *msg)
|
|||
lchan->abis_ip.connect_ip = ntohl(ia.s_addr);
|
||||
lchan->abis_ip.connect_port = ntohs(connect_port);
|
||||
|
||||
} else {
|
||||
/* FIXME: discard all codec frames */
|
||||
}
|
||||
|
||||
rc = osmo_rtp_get_bound_ip_port(lchan->abis_ip.rtp_socket,
|
||||
&lchan->abis_ip.bound_ip,
|
||||
&port);
|
||||
|
|
Loading…
Reference in New Issue