u.ptr = key;
if ((u.i & 0x3) == 0) {
const uint32_t *k = (const uint32_t *)key; /* read 32-bit chunks */
- const uint8_t *k8;
/*------ all but last block: aligned reads and affect 32 bits of (a,b,c) */
while (length > 12)
return MEMCACHED_FAILURE;
}
}
- /* Old connection junk still is in the structure */
- WATCHPOINT_ASSERT(ptr->cursor_active == 0);
if (ptr->sockaddr_inited == MEMCACHED_NOT_ALLOCATED ||
(!(ptr->root->flags & MEM_USE_CACHE_LOOKUPS)))
memcached_return memcached_io_close(memcached_server_st *ptr)
{
int r;
- /* in case of death shutdown to avoid blocking at close() */
+ if (ptr->fd == -1)
+ return MEMCACHED_SUCCESS;
+
+ /* in case of death shutdown to avoid blocking at close() */
r= shutdown(ptr->fd, SHUT_RDWR);
#ifdef HAVE_DEBUG
if (r && errno != ENOTCONN)
{
+ WATCHPOINT_NUMBER(ptr->fd);
WATCHPOINT_ERRNO(errno);
WATCHPOINT_ASSERT(errno);
}
{
int32_t timeout;
char buffer[2048];
- size_t buffer_length= sizeof(buffer);
memcached_result_st result;
if (ptr->root->purging || /* already purging */