Fix memory leaks in memcached_testapp
Fix memory leaks in memcached_testapp

Fix a number of leaks found via Valgrind in testapp.

Note: these arn't leaks in the product - just the tests - but it's
helpful to keep the tests clean to remove any noise.

Change-Id: Icc0bc3a8b46f8788ea709e2fad9cd6e7ab2139b0
Reviewed-on: http://review.couchbase.org/49586
Tested-by: buildbot <80754af91bfb6d1073585b046fe0a474ce868509@couchbase.com>
Reviewed-by: Trond Norbye <60edd2ef23891a753f231b0c6f161dc634079a93@gmail.com>

daverigby/kv_engine,owendCB/memcached,couchbase/memcached,daverigby/memcached,cloudrain21/memcached-1,couchbase/memcached,daverigby/kv_engine,daverigby/kv_engine,daverigby/memcached,cloudrain21/memcached-1,daverigby/memcached,daverigby/kv_engine,couchbase/memcached,cloudrain21/memcached-1,owendCB/memcached,couchbase/memcached,owendCB/memcached,daverigby/memcached,owendCB/memcached,cloudrain21/memcached-1