Commit 21ef822c authored by Robert Schmidt's avatar Robert Schmidt

Shorten IP address buffer to avoid strncpy() warning

parent 9a789dbb
...@@ -1170,8 +1170,10 @@ int DU_handle_UE_CONTEXT_MODIFICATION_REQUEST(instance_t instance, ...@@ -1170,8 +1170,10 @@ int DU_handle_UE_CONTEXT_MODIFICATION_REQUEST(instance_t instance,
extern instance_t DUuniqInstance; extern instance_t DUuniqInstance;
if (DUuniqInstance == 0) { if (DUuniqInstance == 0) {
char gtp_tunnel_ip_address[128]; char gtp_tunnel_ip_address[32];
sprintf(gtp_tunnel_ip_address, "%d.%d.%d.%d", snprintf(gtp_tunnel_ip_address,
sizeof(gtp_tunnel_ip_address),
"%d.%d.%d.%d",
drb_p->up_ul_tnl[0].tl_address & 0xff, drb_p->up_ul_tnl[0].tl_address & 0xff,
(drb_p->up_ul_tnl[0].tl_address >> 8) & 0xff, (drb_p->up_ul_tnl[0].tl_address >> 8) & 0xff,
(drb_p->up_ul_tnl[0].tl_address >> 16) & 0xff, (drb_p->up_ul_tnl[0].tl_address >> 16) & 0xff,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment