summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2011-07-07 23:11:08 -0700
committerDustin Sallings <dustin@spy.net>2011-07-07 23:12:38 -0700
commitbb9d00fe2cb50f54afdae93ec85a103019090160 (patch)
tree4cc704355297fca6afee6e63b7a67c830885fdf4
parentc60ca35b2d1fc36b891f132fbdd2860c3119ccf6 (diff)
downloadmemcached-bb9d00fe2cb50f54afdae93ec85a103019090160.tar.gz
Compile fix (-Werror=unused-but-set-variable warnings)
Assertion is no-longer needed after a conversion from sprintf() to snprintf().
-rw-r--r--items.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/items.c b/items.c
index ee1185e..9cfab93 100644
--- a/items.c
+++ b/items.c
@@ -469,9 +469,7 @@ void do_item_stats_sizes(ADD_STAT add_stats, void *c) {
for (i = 0; i < num_buckets; i++) {
if (histogram[i] != 0) {
char key[8];
- int klen = 0;
- klen = snprintf(key, sizeof(key), "%d", i * 32);
- assert(klen < sizeof(key));
+ snprintf(key, sizeof(key), "%d", i * 32);
APPEND_STAT(key, "%u", histogram[i]);
}
}