*/
#include <libmemcached/common.h>
+#include <libmemcached/options.hpp>
#include <libmemcached/virtual_bucket.h>
#include <ctime>
memcached_literal_param("MEMCACHED_BEHAVIOR_USER_DATA deprecated."));
case MEMCACHED_BEHAVIOR_HASH_WITH_PREFIX_KEY:
- ptr->flags.hash_with_prefix_key= bool(data);
+ ptr->flags.hash_with_namespace= bool(data);
break;
case MEMCACHED_BEHAVIOR_NOREPLY:
uint64_t memcached_behavior_get(memcached_st *ptr,
const memcached_behavior_t flag)
{
+ if (not ptr)
+ {
+ return MEMCACHED_INVALID_ARGUMENTS;
+ }
+
switch (flag)
{
case MEMCACHED_BEHAVIOR_NUMBER_OF_REPLICAS:
return 0;
case MEMCACHED_BEHAVIOR_HASH_WITH_PREFIX_KEY:
- return ptr->flags.hash_with_prefix_key;
+ return ptr->flags.hash_with_namespace;
case MEMCACHED_BEHAVIOR_NOREPLY:
return ptr->flags.no_reply;