X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;f=libmemcached%2Fauto.cc;h=df4ceb2fd2f1025f5415e05e3a05675a821570ee;hb=983523c4536f12781533124cb8a00a4291b8cf79;hp=9d85ad434858897556244f0447f0564cfddadaf5;hpb=3dcd41c50068eec906a1a11a178e9b3f08ef2326;p=m6w6%2Flibmemcached diff --git a/libmemcached/auto.cc b/libmemcached/auto.cc index 9d85ad43..df4ceb2f 100644 --- a/libmemcached/auto.cc +++ b/libmemcached/auto.cc @@ -166,6 +166,12 @@ static memcached_return_t increment_decrement_by_key(const protocol_binary_comma 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); @@ -219,6 +225,12 @@ static memcached_return_t increment_decrement_with_initial_by_key(const protocol 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);