aboutsummaryrefslogtreecommitdiffstats
path: root/extras
diff options
context:
space:
mode:
authorMohsin Kazmi <sykazmi@cisco.com>2018-12-06 08:36:55 -0800
committerNeale Ranns <nranns@cisco.com>2018-12-07 09:42:34 +0000
commit920fd77e9c78860b42dc9250a85288152de007d7 (patch)
tree91ebf9ec42bd2c3eb99888b085bba174c7e24b7b /extras
parent91afaab068e4f3452eda35053959a9015ae1d0d0 (diff)
vom: Fix the api type definition
Change-Id: I1e5f5a0d60745a42e6efaab3b6eb49b6b0e74e36 Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Diffstat (limited to 'extras')
-rw-r--r--extras/vom/vom/api_types.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/extras/vom/vom/api_types.cpp b/extras/vom/vom/api_types.cpp
index 1bde8be9dcc..9615410a036 100644
--- a/extras/vom/vom/api_types.cpp
+++ b/extras/vom/vom/api_types.cpp
@@ -71,11 +71,13 @@ from_api(const vapi_type_prefix& v)
return route::prefix_t(from_api(v.address), v.address_length);
}
-void
-to_api(const route::prefix_t& p, vapi_type_prefix& v)
+vapi_type_prefix
+to_api(const route::prefix_t& p)
{
+ vapi_type_prefix v;
to_api(p.address(), v.address);
v.address_length = p.mask_width();
+ return v;
}
};