osmith has uploaded this change for review. (
https://gerrit.osmocom.org/c/libgtpnl/+/34738?usp=email )
Change subject: gtp-genl: allocate room for maximum IPv6 address
......................................................................
gtp-genl: allocate room for maximum IPv6 address
Otherwise, inet_ntop() might return ENOSPC because of the buffer
being too small to accomodate an IPv6 address.
Change-Id: I2283e0c3112bec8e6e7e7b5c96657facc09d0a7a
---
M src/gtp-genl.c
1 file changed, 13 insertions(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/libgtpnl refs/changes/38/34738/1
diff --git a/src/gtp-genl.c b/src/gtp-genl.c
index 0c90894..4e4e63d 100644
--- a/src/gtp-genl.c
+++ b/src/gtp-genl.c
@@ -187,7 +187,7 @@
static int genl_gtp_attr_cb(const struct nlmsghdr *nlh, void *data)
{
struct nlattr *tb[GTPA_MAX + 1] = {};
- char buf[INET_ADDRSTRLEN];
+ char buf[INET6_ADDRSTRLEN];
struct gtp_pdp pdp = {};
struct genlmsghdr *genl;
--
To view, visit
https://gerrit.osmocom.org/c/libgtpnl/+/34738?usp=email
To unsubscribe, or for help writing mail filters, visit
https://gerrit.osmocom.org/settings
Gerrit-Project: libgtpnl
Gerrit-Branch: master
Gerrit-Change-Id: I2283e0c3112bec8e6e7e7b5c96657facc09d0a7a
Gerrit-Change-Number: 34738
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <osmith(a)sysmocom.de>
Gerrit-MessageType: newchange