mirror of
https://gitea.osmocom.org/cellular-infrastructure/osmo-mgw.git
synced 2025-11-02 04:53:24 +00:00
bsc_msc_ip: Specify the size we can read directly...
data_len is wrong as well as we have reserved... specifying it directly seems to make valgrind happy. This also means that we might receive more than one UDP message and do not properly forward things. I will need to investigate.
This commit is contained in:
@@ -612,7 +612,7 @@ static int mgcp_do_read(struct bsc_fd *fd)
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
ret = read(fd->fd, mgcp->data, mgcp->data_len);
|
ret = read(fd->fd, mgcp->data, 4096 - 128);
|
||||||
if (ret <= 0) {
|
if (ret <= 0) {
|
||||||
LOGP(DMGCP, LOGL_ERROR, "Failed to read: %d/%s\n", errno, strerror(errno));
|
LOGP(DMGCP, LOGL_ERROR, "Failed to read: %d/%s\n", errno, strerror(errno));
|
||||||
msgb_free(mgcp);
|
msgb_free(mgcp);
|
||||||
|
|||||||
Reference in New Issue
Block a user