projects
/
m6w6
/
libmemcached
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
|
github
raw
|
inline
| side by side
This includes work for partitioning by key. Dormando wished for these methods.
[m6w6/libmemcached]
/
lib
/
memcached_response.c
diff --git
a/lib/memcached_response.c
b/lib/memcached_response.c
index 78b314f42dc47864c15cc622ceea7b2a9f25cdba..076b0a6fc2bd67a49c3d5d22e50f9405102c0553 100644
(file)
--- a/
lib/memcached_response.c
+++ b/
lib/memcached_response.c
@@
-43,6
+43,9
@@
memcached_return memcached_response(memcached_st *ptr,
total_length++;
WATCHPOINT_ASSERT(total_length < buffer_length);
total_length++;
WATCHPOINT_ASSERT(total_length < buffer_length);
+
+ if (total_length >= buffer_length)
+ return MEMCACHED_PROTOCOL_ERROR;
}
buffer_ptr++;
*buffer_ptr= 0;
}
buffer_ptr++;
*buffer_ptr= 0;