From: Brian Aker Date: Tue, 18 Dec 2007 09:36:49 +0000 (-0800) Subject: Fix to make all keys null terminated (sort of surprised that I had not done X-Git-Tag: 0.13~20 X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=29025a471a0e531c4447f1e91eb148ca0f64689a;p=awesomized%2Flibmemcached Fix to make all keys null terminated (sort of surprised that I had not done this before) --- diff --git a/ChangeLog b/ChangeLog index d2017cf4..ee8246d2 100644 --- a/ChangeLog +++ b/ChangeLog @@ -4,6 +4,7 @@ * Lingering socket fixes for FreeBSD. * Patches from Kevin Dalley for FreeBSD 4.0 * Added multi delete functions. + * All get key returns have C style null termination 0.12 Tue Dec 11 15:20:55 PST 2007 * Updates for consistent hashing diff --git a/lib/memcached_fetch.c b/lib/memcached_fetch.c index 67338835..257bfbc4 100644 --- a/lib/memcached_fetch.c +++ b/lib/memcached_fetch.c @@ -35,6 +35,7 @@ memcached_return value_fetch(memcached_st *ptr, key++; result->key_length++; } + result->key[result->key_length]= 0; } if (end_ptr == string_ptr)