Made sure memory was freed after call to memcached_get_by_key.
authorPadraig O'Sullivan <osullivan.padraig@gmail.com>
Tue, 20 Oct 2009 17:39:42 +0000 (13:39 -0400)
committerPadraig O'Sullivan <osullivan.padraig@gmail.com>
Tue, 20 Oct 2009 17:39:42 +0000 (13:39 -0400)
libmemcached/memcached.hpp

index 45dba9d321426f9ae5a27c7bbd1049be2f97e60c..2a533e018053d40cb83ea2fe9d8df1135d733600 100644 (file)
@@ -303,6 +303,7 @@ public:
     {
       ret_val.reserve(value_length);
       ret_val.assign(value, value + value_length);
+      free(value);
       return true;
     }
     return false;