X-Git-Url: http://review.tizen.org/git/?p=platform%2Fupstream%2Fiotivity.git;a=blobdiff_plain;f=resource%2Fcsdk%2Fconnectivity%2Flib%2Flibcoap-4.1.1%2Finclude%2Fcoap%2Futlist.h;fp=resource%2Fcsdk%2Fconnectivity%2Flib%2Flibcoap-4.1.1%2Futlist.h;h=1889a8e16e28ad659067dc65ca9721635daa573d;hp=a1c739c0197ea8bc3300e676d00de63bc42f47a9;hb=94651923bf67705c1b4bd61ab251e8c598d2a807;hpb=1cee1631595cac6a6394ac2e0b365c6dd5a42c68 diff --git a/resource/csdk/connectivity/lib/libcoap-4.1.1/utlist.h b/resource/csdk/connectivity/lib/libcoap-4.1.1/include/coap/utlist.h similarity index 99% rename from resource/csdk/connectivity/lib/libcoap-4.1.1/utlist.h rename to resource/csdk/connectivity/lib/libcoap-4.1.1/include/coap/utlist.h index a1c739c..1889a8e 100644 --- a/resource/csdk/connectivity/lib/libcoap-4.1.1/utlist.h +++ b/resource/csdk/connectivity/lib/libcoap-4.1.1/include/coap/utlist.h @@ -62,7 +62,7 @@ when compiling c++ code), this code uses whatever method is needed or, for VS2008 where neither is available, uses casting workarounds. */ #ifdef _MSC_VER /* MS compiler */ -#if _MSC_VER >= 1600 && __cplusplus /* VS2010 and newer in C++ mode */ +#if (_MSC_VER >= 1600) && (defined(__cplusplus) && (__cplusplus >= 201103L)) /* VS2010 and newer in C++ mode */ #define LDECLTYPE(x) decltype(x) #else /* VS2008 or older (or VS2010 in C mode) */ #define NO_DECLTYPE @@ -338,11 +338,11 @@ do { (head)=(head)->next; \ } else { \ char *_tmp = (char*)(head); \ - while (head->next && (head->next != (del))) { \ - head = head->next; \ + while ((head)->next && ((head)->next != (del))) { \ + (head) = (head)->next; \ } \ - if (head->next) { \ - head->next = ((del)->next); \ + if ((head)->next) { \ + (head)->next = ((del)->next); \ } \ { \ char **_head_alias = (char**)&(head); \