{ memcached_literal_param("incr ") },
{ memcached_array_string(instance->root->_namespace), memcached_array_size(instance->root->_namespace) },
{ key, key_length },
- { buffer, send_length },
+ { buffer, size_t(send_length) },
{ " noreply", reply ? 0 : memcached_literal_param_size(" noreply") },
{ memcached_literal_param("\r\n") }
};
}
protocol_binary_request_incr request= {}; // = {.bytes= {0}};
- request.message.header.request.magic= PROTOCOL_BINARY_REQ;
+ initialize_binary_request(instance, request.message.header);
+
request.message.header.request.opcode= cmd;
request.message.header.request.keylen= htons((uint16_t)(key_length + memcached_array_size(instance->root->_namespace)));
request.message.header.request.extlen= 20;
return rc;
}
+ if (memcached_is_encrypted(memc))
+ {
+ return memcached_set_error(*memc, MEMCACHED_NOT_SUPPORTED, MEMCACHED_AT,
+ memcached_literal_param("Operation not allowed while encyrption is enabled"));
+ }
+
if (memcached_failed(rc= memcached_key_test(*memc, (const char **)&key, &key_length, 1)))
{
return memcached_last_error(memc);
return rc;
}
+ if (memcached_is_encrypted(memc))
+ {
+ return memcached_set_error(*memc, MEMCACHED_NOT_SUPPORTED, MEMCACHED_AT,
+ memcached_literal_param("Operation not allowed while encyrption is enabled"));
+ }
+
if (memcached_failed(rc= memcached_key_test(*memc, (const char **)&key, &key_length, 1)))
{
return memcached_last_error(memc);