diff options
author | Mauro Sardara <msardara@cisco.com> | 2019-10-07 14:37:42 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@fd.io> | 2019-10-07 14:37:42 +0000 |
commit | 7896701a177d66f376172ab43df4b0c1d5d867a3 (patch) | |
tree | a89986dcceb1d5b6faa7ae529b1d4a1e9f4d6d85 /libtransport/src/hicn/transport/core/content_object.cc | |
parent | 108c55669102931acc9bd99ca9918379722732b8 (diff) | |
parent | 6b84ec54083da9911f5ad4816d0eb4f4745afad4 (diff) |
Merge "[HICN-298] Release new hICN app for Android"
Diffstat (limited to 'libtransport/src/hicn/transport/core/content_object.cc')
-rw-r--r-- | libtransport/src/hicn/transport/core/content_object.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/libtransport/src/hicn/transport/core/content_object.cc b/libtransport/src/hicn/transport/core/content_object.cc index 83b545c05..d05239372 100644 --- a/libtransport/src/hicn/transport/core/content_object.cc +++ b/libtransport/src/hicn/transport/core/content_object.cc @@ -22,6 +22,7 @@ extern "C" { TRANSPORT_CLANG_DISABLE_WARNING("-Wextern-c-compat") #endif #include <hicn/hicn.h> +#include <hicn/util/ip_address.h> } #include <cstring> @@ -153,7 +154,7 @@ ContentObject &ContentObject::setPathLabel(uint32_t path_label) { return *this; } -void ContentObject::setLocator(const ip_address_t &ip_address) { +void ContentObject::setLocator(const ip_prefix_t &ip_address) { if (hicn_data_set_locator(format_, packet_start_, &ip_address) < 0) { throw errors::RuntimeException("Error setting content object locator"); } @@ -161,8 +162,8 @@ void ContentObject::setLocator(const ip_address_t &ip_address) { return; } -ip_address_t ContentObject::getLocator() const { - ip_address_t ip; +ip_prefix_t ContentObject::getLocator() const { + ip_prefix_t ip; if (hicn_data_get_locator(format_, packet_start_, &ip) < 0) { throw errors::RuntimeException("Error getting content object locator."); |