pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmocore/+/35290?usp=email )
Change subject: socket: Fix uninitialized mem ptr free in osmo_sock_init2_multiaddr2()
......................................................................
socket: Fix uninitialized mem ptr free in osmo_sock_init2_multiaddr2()
The goto tag was wrong, probably due to a copy-paste mistype while
reimplementing the function.
Closes: Coverity CID#336546
Change-Id: I06b810fde7bf750fcb42d6d9e6223883e26f5f0b
---
M src/core/socket.c
1 file changed, 14 insertions(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/90/35290/1
diff --git a/src/core/socket.c b/src/core/socket.c
index c600732..5b7489d 100644
--- a/src/core/socket.c
+++ b/src/core/socket.c
@@ -905,7 +905,7 @@
if (family == AF_INET && loc_has_v6only_addr) {
LOGP(DLGLOBAL, LOGL_ERROR, "Cannot bind an IPv6 address to an AF_INET socket\n");
rc = -EINVAL;
- goto ret_freeaddrinfo;
+ goto ret_freeaddrinfo_loc;
}
}
/* figure out remote side of socket */
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/35290?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I06b810fde7bf750fcb42d6d9e6223883e26f5f0b
Gerrit-Change-Number: 35290
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newchange
fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bsc/+/35288?usp=email )
Change subject: gsm_data: fix wrong variable set in gsm_pchan2chan_nr()
......................................................................
gsm_data: fix wrong variable set in gsm_pchan2chan_nr()
I believe the actual intention was to reset the 'lchan_nr' variable,
and not the 'chan_nr'. The 'lchan_nr' is used to compose the 'cbits':
cbits = 0x04;
cbits += lchan_nr;
If the value is 4, then the result is:
cbits = 0x04 + 4 = 0x08
which corresponds to SDCCH8 (not SDCCH4), and is clearly wrong.
Change-Id: Ic9c7c2e46e24dab0b721221e9adcbbae2ca56d23
Fixes: ec1b5a0e9 "gsm_ts2chan_nr(): add assertions for lchan_nr"
Fixes: CID#336586
---
M src/osmo-bsc/gsm_data.c
1 file changed, 25 insertions(+), 2 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bsc refs/changes/88/35288/1
diff --git a/src/osmo-bsc/gsm_data.c b/src/osmo-bsc/gsm_data.c
index 580fa84..4d77e75 100644
--- a/src/osmo-bsc/gsm_data.c
+++ b/src/osmo-bsc/gsm_data.c
@@ -485,8 +485,8 @@
* See osmo-bts-xxx/oml.c:opstart_compl().
*/
if (lchan_nr == CCCH_LCHAN)
- chan_nr = 0;
- else if (lchan_nr >= 4)
+ lchan_nr = 0;
+ else if (lchan_nr > 4)
return -EINVAL;
cbits = 0x04;
cbits += lchan_nr;
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/35288?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: Ic9c7c2e46e24dab0b721221e9adcbbae2ca56d23
Gerrit-Change-Number: 35288
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-MessageType: newchange
pespin has uploaded a new patch set (#2). ( https://gerrit.osmocom.org/c/libosmo-netif/+/35286?usp=email )
Change subject: stream_cli: Introduce API osmo_stream_srv_get_sockname()
......................................................................
stream_cli: Introduce API osmo_stream_srv_get_sockname()
Similar to what osmo_stream_srv_link and osmo_stream_cli already have.
Change-Id: I171befd1fdf40c3cbb3fc7e4c3eedf82128b0712
Related: SYS#5580
---
M TODO-RELEASE
M include/osmocom/netif/stream.h
M src/stream_srv.c
3 files changed, 27 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmo-netif refs/changes/86/35286/2
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/35286?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: I171befd1fdf40c3cbb3fc7e4c3eedf82128b0712
Gerrit-Change-Number: 35286
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-CC: Jenkins Builder
Gerrit-MessageType: newpatchset
Hello Jenkins Builder,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/libosmo-netif/+/35285?usp=email
to look at the new patch set (#2).
The following approvals got outdated and were removed:
Verified+1 by Jenkins Builder
Change subject: stream_cli: osmo_stream_cli_get_sockname() now returns the full set of addresses
......................................................................
stream_cli: osmo_stream_cli_get_sockname() now returns the full set of addresses
This is used by API callers, and internally to log
connected/disconnected events.
Related: SYS#5581
Change-Id: I249ee7cad824cf971faabe06d10de2426c1b0c8b
---
M TODO-RELEASE
M src/stream_cli.c
2 files changed, 18 insertions(+), 3 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmo-netif refs/changes/85/35285/2
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/35285?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: I249ee7cad824cf971faabe06d10de2426c1b0c8b
Gerrit-Change-Number: 35285
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-MessageType: newpatchset
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmo-netif/+/35285?usp=email )
Change subject: stream_cli: osmo_stream_cli_get_sockname() now returns the full set of addresses
......................................................................
stream_cli: osmo_stream_cli_get_sockname() now returns the full set of addresses
This is used by API callers, and internally to log
connected/disconnected events.
Related: SYS#5581
Change-Id: I249ee7cad824cf971faabe06d10de2426c1b0c8b
---
M src/stream_cli.c
1 file changed, 16 insertions(+), 2 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmo-netif refs/changes/85/35285/1
diff --git a/src/stream_cli.c b/src/stream_cli.c
index 4f2963d..1b9994c 100644
--- a/src/stream_cli.c
+++ b/src/stream_cli.c
@@ -685,9 +685,10 @@
* \returns Socket description or NULL in case of error */
char *osmo_stream_cli_get_sockname(const struct osmo_stream_cli *cli)
{
- static char buf[OSMO_SOCK_NAME_MAXLEN];
+ static char buf[OSMO_STREAM_MAX_ADDRS * OSMO_SOCK_NAME_MAXLEN];
- osmo_sock_get_name_buf(buf, OSMO_SOCK_NAME_MAXLEN, osmo_stream_cli_get_fd(cli));
+ osmo_sock_multiaddr_get_name_buf(buf, sizeof(buf),
+ osmo_stream_cli_get_fd(cli), cli->proto);
return buf;
}
--
To view, visit https://gerrit.osmocom.org/c/libosmo-netif/+/35285?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-netif
Gerrit-Branch: master
Gerrit-Change-Id: I249ee7cad824cf971faabe06d10de2426c1b0c8b
Gerrit-Change-Number: 35285
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newchange