This is a set of code that will sometimes have a warning
depending on what is defined. To prevent the
unused-parameter warning the parameters are cast to void.
A empty operation that will be compiled out but prevents
the warning.
Bug: https://jira.iotivity.org/browse/IOT-2539
Change-Id: I08c73fb565b62d3a760956976a012331863a6c73
Signed-off-by: George Nash <george.nash@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/21769
Tested-by: jenkins-iotivity <jenkins@iotivity.org>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
(cherry picked from commit
598e8c5b7e7ad9cfc6fab77f5843e5e390509728)
size_t
coap_print_addr(const struct coap_address_t *addr, unsigned char *buf, size_t len) {
+ // Depending on what is defined its possible that the input parameters
+ // are not used. Cast them to void avoid unused-parameter warnings
+ (void)addr;
+ (void)buf;
+ (void)len;
#if defined(HAVE_ARPA_INET_H) || defined(_WIN32)
const void *addrptr = NULL;
#if defined(__ANDROID__)