summaryrefslogtreecommitdiff
path: root/slabs.h
diff options
context:
space:
mode:
authorDustin Sallings <dustin@spy.net>2008-10-27 19:23:29 -0700
committerDustin Sallings <dustin@spy.net>2009-01-03 00:09:13 -0800
commitbd6a82787f9030090a2a2713ad12411240a8039e (patch)
tree87c09caf8d9477aa7220e0aef3513282962a3d94 /slabs.h
parent07e6d4fb6354be2494a14e7da11877b6709f4d37 (diff)
downloadmemcached-bd6a82787f9030090a2a2713ad12411240a8039e.tar.gz
Fix for binary stats with subcommand.
The subcommand is not necessarily a null terminated string (in the case of the binary protocol, it certainly isn't). The subcommand would not be recognized due to strcmp() failing. Tested with both text and binary protocols.
Diffstat (limited to 'slabs.h')
-rw-r--r--slabs.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/slabs.h b/slabs.h
index 78f2864..88304d1 100644
--- a/slabs.h
+++ b/slabs.h
@@ -23,7 +23,8 @@ void *do_slabs_alloc(const size_t size, unsigned int id);
void do_slabs_free(void *ptr, size_t size, unsigned int id);
/** Return a datum for stats in binary protocol */
-char *get_stats(const char *stat_type, uint32_t (*add_stats)(char *buf,
+char *get_stats(const char *stat_type, int nkey,
+ uint32_t (*add_stats)(char *buf,
const char *key, const uint16_t klen, const char *val,
const uint32_t vlen, void *cookie), void *arg, int *buflen);