X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;f=lib%2Fmemcached_behavior.c;h=c54d93fcd4ba03d094e591431750be2f76c867f5;hb=edeb3965773b750c0cf454e8b1494fd030ba0369;hp=910fb392e9e27e729d03c9359f0bf28bacfe2125;hpb=52d5f8e32ae6e26932a07749ef5d5640e815a3f7;p=m6w6%2Flibmemcached diff --git a/lib/memcached_behavior.c b/lib/memcached_behavior.c index 910fb392..c54d93fc 100644 --- a/lib/memcached_behavior.c +++ b/lib/memcached_behavior.c @@ -31,10 +31,15 @@ memcached_return memcached_behavior_set(memcached_st *ptr, break; case MEMCACHED_BEHAVIOR_NO_BLOCK: set_behavior_flag(ptr, MEM_NO_BLOCK, data); + case MEMCACHED_BEHAVIOR_BUFFER_REQUESTS: + set_behavior_flag(ptr, MEM_BUFFER_REQUESTS, data); break; case MEMCACHED_BEHAVIOR_TCP_NODELAY: set_behavior_flag(ptr, MEM_TCP_NODELAY, data); break; + case MEMCACHED_BEHAVIOR_DISTRIBUTION: + ptr->distribution= *(memcached_server_distribution *)(data); + break; case MEMCACHED_BEHAVIOR_HASH: ptr->hash= *(memcached_hash *)(data); break; @@ -86,9 +91,14 @@ unsigned long long memcached_behavior_get(memcached_st *ptr, case MEMCACHED_BEHAVIOR_NO_BLOCK: temp_flag= MEM_NO_BLOCK; break; + case MEMCACHED_BEHAVIOR_BUFFER_REQUESTS: + temp_flag= MEM_BUFFER_REQUESTS; + break; case MEMCACHED_BEHAVIOR_TCP_NODELAY: temp_flag= MEM_TCP_NODELAY; break; + case MEMCACHED_BEHAVIOR_DISTRIBUTION: + return ptr->distribution; case MEMCACHED_BEHAVIOR_HASH: return ptr->hash; case MEMCACHED_BEHAVIOR_KETAMA: