SILC_LOG_DEBUG(("URI: '%s'", conn->uri));
/* Protocol version compatibility */
- tmp = memchr(tmp, '\0', data_len - (tmp - data)) + 1;
+ tmp = ((unsigned char *)memchr(tmp, '\0', data_len - (tmp - data))) + 1;
SILC_LOG_DEBUG(("Protocol: %s", tmp));
if (strstr(tmp, "HTTP/1.0"))
conn->keepalive = FALSE;
#elif defined(SILC_WIN32)
/* Windows */
- return InterlockedCompareExchangePointer(&atomic->value, n, o) == o;
+ return InterlockedCompareExchangePointer(&atomic->value, new_val, old_val)
+ == old_val;
#elif defined(__GNUC__) && defined(SILC_I486)
/* GCC + i486 */