X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;ds=sidebyside;f=lib%2Fmemcached_storage.c;h=38d6d0db3ca689ccb75d3717bdef30930ab488a9;hb=434db1f50f8d36ff2d5d52973ccfd963392470f7;hp=5f69413564dcdcc9dc1f9d20becedc8b40f013dc;hpb=79892ee7f064bbbb7768ec7ed700655da2c35275;p=m6w6%2Flibmemcached diff --git a/lib/memcached_storage.c b/lib/memcached_storage.c index 5f694135..38d6d0db 100644 --- a/lib/memcached_storage.c +++ b/lib/memcached_storage.c @@ -20,7 +20,7 @@ typedef enum { } memcached_storage_action; /* Inline this */ -char *storage_op_string(memcached_storage_action verb) +static char *storage_op_string(memcached_storage_action verb) { switch (verb) { @@ -96,7 +96,7 @@ static inline memcached_return memcached_send(memcached_st *ptr, goto error; } - if ((ptr->flags & MEM_NO_BLOCK) && verb == SET_OP) + if ((ptr->flags & MEM_BUFFER_REQUESTS) && verb == SET_OP) to_write= 0; else to_write= 1; @@ -108,9 +108,9 @@ static inline memcached_return memcached_send(memcached_st *ptr, } if (to_write == 0) - rc= MEMCACHED_SUCCESS; - else - rc= memcached_response(ptr, buffer, MEMCACHED_DEFAULT_COMMAND_SIZE, server_key); + return MEMCACHED_BUFFERED; + + rc= memcached_response(ptr, buffer, MEMCACHED_DEFAULT_COMMAND_SIZE, NULL, server_key); if (rc == MEMCACHED_STORED) return MEMCACHED_SUCCESS;