aboutsummaryrefslogtreecommitdiffstats
path: root/src/gprs/gtphub.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gprs/gtphub.c')
-rw-r--r--src/gprs/gtphub.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gprs/gtphub.c b/src/gprs/gtphub.c
index 2ff1b7cd..4ee20cdc 100644
--- a/src/gprs/gtphub.c
+++ b/src/gprs/gtphub.c
@@ -2649,7 +2649,9 @@ struct gtphub_peer_port *gtphub_port_find_sa(const struct gtphub_bind *bind,
{
struct gsn_addr gsna;
uint16_t port;
- gsn_addr_from_sockaddr(&gsna, &port, addr);
+ if (gsn_addr_from_sockaddr(&gsna, &port, addr) != 0)
+ return NULL;
+
return gtphub_port_find(bind, &gsna, port);
}