diff options
author | Jordan Augé <jordan.auge+fdio@cisco.com> | 2020-04-27 09:42:17 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@fd.io> | 2020-04-27 09:42:17 +0000 |
commit | e94a00b51ce795a8629c33edefd3fcd4b4af05ef (patch) | |
tree | da6b4eb58ec6cb6042b21b05fa194fad9b5d6b8e /hicn-light/src/hicn/utils/utils.h | |
parent | 0ea5735b98f38beacf92dfdca74b7a6d5b3f7182 (diff) | |
parent | 15ad172a847fa667c57a4594ef4158405db9a984 (diff) |
Merge "[HICN-554] hicn-light refactoring" into hicn-light-ng
Diffstat (limited to 'hicn-light/src/hicn/utils/utils.h')
-rw-r--r-- | hicn-light/src/hicn/utils/utils.h | 36 |
1 files changed, 8 insertions, 28 deletions
diff --git a/hicn-light/src/hicn/utils/utils.h b/hicn-light/src/hicn/utils/utils.h index 1fe88e62c..368a93f5a 100644 --- a/hicn-light/src/hicn/utils/utils.h +++ b/hicn-light/src/hicn/utils/utils.h @@ -16,8 +16,7 @@ #ifndef utils_h #define utils_h -#include <hicn/config/controlState.h> -#include <hicn/utils/address.h> +//#include <hicn/config/controlState.h> #include <hicn/utils/commands.h> /** @@ -32,39 +31,20 @@ bool utils_IsNumber(const char *string); bool utils_ValidateSymbolicName(const char *symbolic); /** - *Create an Ack message instance as a response of a control successfully - *completed. - */ -struct iovec *utils_CreateAck(header_control_message *header, void *payload, - size_t payloadLen); - -/** - *Create a Nack message instance as a response of a control unsuccessfully - *completed. - */ -struct iovec *utils_CreateNack(header_control_message *header, void *payload, - size_t payloadLen); - -/** *Convert IPv4/IPv6 address from binary to text string. `uint8_t *ipAddress` has *to be a `in_addr_t * or `a struct in6_addr *. */ -char *utils_CommandAddressToString(address_type addressType, - ip_address_t *address, in_port_t *port); +char *utils_CommandAddressToString(int family, ip_address_t *address, + in_port_t *port); /** *Given a command payload, it generates the header and send the request to the *deamon. */ -struct iovec *utils_SendRequest(ControlState *state, command_id command, - void *payload, size_t payloadLen); - -/** - *Convert a IPv4/IPv6 address plus Netmask len from binary to text string in the - *form [add]:[port]/[len]. - */ -const char *utils_PrefixLenToString(address_type addressType, - ip_address_t *address, - uint8_t *prefixLen); +#if 0 +struct iovec * +utils_SendRequest(ControlState *state, command_type_t + command_type, void *payload, size_t payloadLen); #endif +#endif |