X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;ds=sidebyside;f=tests%2Fparser.cc;h=40904a085ce3fb435205782eb3288401071a04df;hb=b6c4c56795a26e6191224bfae64f382db3f68f7a;hp=d559b84d1776188f0a59bbc0eae21f1863fa541c;hpb=833ab6461e5066f3b88663dc8b64efaa65da54bd;p=awesomized%2Flibmemcached diff --git a/tests/parser.cc b/tests/parser.cc index d559b84d..40904a08 100644 --- a/tests/parser.cc +++ b/tests/parser.cc @@ -521,11 +521,10 @@ test_return_t random_statement_build_test(memcached_st *junk) random_options+= option_list[random() % option_list.size()]->c_str; random_options+= " "; } - random_options.resize(random_options.size() -1); memcached_return_t rc; memcached_st *memc_ptr= memcached_create(NULL); - rc= memcached_parse_configuration(memc_ptr, random_options.c_str(), random_options.size()); + rc= memcached_parse_configuration(memc_ptr, random_options.c_str(), random_options.size() -1); if (rc == MEMCACHED_PARSE_ERROR) { std::cerr << std::endl << "Failed to parse(" << memcached_strerror(NULL, rc) << "): " << random_options << std::endl;