From: Michael Wallner Date: Tue, 21 Jan 2020 11:40:15 +0000 (+0100) Subject: libmemcached: recognize more server out of memory conditions X-Git-Tag: pre_cmake~29 X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=d234ba4d3903a1284c02d45d86ef816fd696c13a;p=awesomized%2Flibmemcached libmemcached: recognize more server out of memory conditions --- diff --git a/libmemcached/response.cc b/libmemcached/response.cc index ad3c0785..79ab7e65 100644 --- a/libmemcached/response.cc +++ b/libmemcached/response.cc @@ -309,8 +309,9 @@ static memcached_return_t textual_read_one_response(memcached_instance_st* insta return MEMCACHED_E2BIG; } - if (total_read >= memcached_literal_param_size("SERVER_ERROR out of memory storing object") and - (memcmp(buffer, memcached_literal_param("SERVER_ERROR out of memory storing object")) == 0)) + if (total_read >= memcached_literal_param_size("SERVER_ERROR out of memory") and + ((memcmp(buffer, memcached_literal_param("SERVER_ERROR out of memory")) == 0) or + (memcmp(buffer, memcached_literal_param("SERVER_ERROR Out of memory")) == 0))) { return MEMCACHED_SERVER_MEMORY_ALLOCATION_FAILURE; }