aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMauro Sardara <msardara@cisco.com>2023-01-20 11:05:16 +0000
committerGerrit Code Review <gerrit@fd.io>2023-01-20 11:05:16 +0000
commit5775adb22b4e6a54a293928c67890149e6f6300d (patch)
tree850895c2dedcce7606dadef74d332d1bcd887c8a
parent0771b15a15b84be06c8cc80dc8311e035444c596 (diff)
parenta465d503193cc75052aa5acb9babfdd369cda90c (diff)
Merge "fix(libhicnctrl)/hicn_plugin): copy address to correct offset"
-rw-r--r--ctrl/libhicnctrl/src/modules/hicn_plugin/listener.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ctrl/libhicnctrl/src/modules/hicn_plugin/listener.c b/ctrl/libhicnctrl/src/modules/hicn_plugin/listener.c
index 0e9c5406d..4d9792256 100644
--- a/ctrl/libhicnctrl/src/modules/hicn_plugin/listener.c
+++ b/ctrl/libhicnctrl/src/modules/hicn_plugin/listener.c
@@ -44,11 +44,11 @@ static vapi_error_e process_ip_info(struct vapi_ctx_s *ctx, void *callback_ctx,
struct listener_data_s *ld = (struct listener_data_s *)callback_ctx;
if (reply->prefix.address.af == ADDRESS_IP4) {
- memcpy(&(ld->listener.local_addr), reply->prefix.address.un.ip4,
+ memcpy(&(ld->listener.local_addr.v4), reply->prefix.address.un.ip4,
IPV4_ADDR_LEN);
ld->listener.family = AF_INET;
} else {
- memcpy(&(ld->listener.local_addr), reply->prefix.address.un.ip6,
+ memcpy(&(ld->listener.local_addr.v6), reply->prefix.address.un.ip6,
IPV6_ADDR_LEN);
ld->listener.family = AF_INET6;
}