From: Brian Aker Date: Tue, 6 Jan 2009 22:40:14 +0000 (-0800) Subject: Fix for test case to not leak memory. X-Git-Tag: 0.26~25 X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=1fee60dd819fca65b9ff2fa24602ad2217198dab;p=m6w6%2Flibmemcached Fix for test case to not leak memory. --- diff --git a/tests/function.c b/tests/function.c index 411c12b6..5164b828 100644 --- a/tests/function.c +++ b/tests/function.c @@ -2176,12 +2176,17 @@ test_return user_supplied_bug20(memcached_st *memc) status = memcached_mget(memc, &key, &key_len, 1); assert(status == MEMCACHED_SUCCESS); + result= memcached_result_create(memc, &result_obj); + assert(result); + memcached_result_create(memc, &result_obj); result= memcached_fetch_result(memc, &result_obj, &status); assert(result); assert(status == MEMCACHED_SUCCESS); + memcached_result_free(result); + return 0; }