Couple of bugfixes to memcache