0
@@ -51,7 +51,7 @@ void item_init(void) {
0
# define DEBUG_REFCNT(it,op) while(0)
0
* Generates the variable-sized part of the header for an object.
0
@@ -150,7 +150,7 @@ void item_free(item *it) {
0
slabs_free(it, ntotal);
0
* Returns true if an item will fit in the cache (its size does not exceed
0
* the maximum for a cache entry.)
0
@@ -267,12 +267,12 @@ int do_item_replace(item *it, item *new_it) {
0
char *do_item_cachedump(const unsigned int slabs_clsid, const unsigned int limit, unsigned int *bytes) {
0
-
int memlimit = 2 * 1024 * 1024; /* 2MB max response size */
0
+
unsigned int memlimit = 2 * 1024 * 1024; /* 2MB max response size */
0
+ unsigned int shown = 0;
0
if (slabs_clsid > LARGEST_ID) return NULL;
0
@@ -332,7 +332,7 @@ char *do_item_stats(int *bytes) {
0
-/*
dumps out a list of objects of each size, with granularity of 32 bytes */
0
+/*
* dumps out a list of objects of each size, with granularity of 32 bytes */
0
char* do_item_stats_sizes(int *bytes) {
0
const int num_buckets = 32768; /* max 1MB object, divided into 32 bytes size buckets */
0
@@ -371,14 +371,14 @@ char* do_item_stats_sizes(int *bytes) {
0
-/* returns true if a deleted item's delete-locked-time is over, and it
0
- should be removed from the namespace */
0
+/** returns true if a deleted item's delete-locked-time is over, and it
0
+ should be removed from the namespace */
0
bool item_delete_lock_over (item *it) {
0
assert(it->it_flags & ITEM_DELETED);
0
return (current_time >= it->exptime);
0
-/*
wrapper around assoc_find which does the lazy expiration/deletion logic */
0
+/*
* wrapper around assoc_find which does the lazy expiration/deletion logic */
0
item *do_item_get_notedeleted(const char *key, const size_t nkey, bool *delete_locked) {
0
item *it = assoc_find(key, nkey);
0
if (delete_locked) *delete_locked = false;
0
@@ -393,11 +393,11 @@ item *do_item_get_notedeleted(const char *key, const size_t nkey, bool *delete_l
0
if (it != NULL && settings.oldest_live != 0 && settings.oldest_live <= current_time &&
0
it->time <= settings.oldest_live) {
0
- do_item_unlink(it); /
/ MTSAFE - cache_lock held0
+ do_item_unlink(it); /
* MTSAFE - cache_lock held */0
if (it != NULL && it->exptime != 0 && it->exptime <= current_time) {
0
- do_item_unlink(it); /
/ MTSAFE - cache_lock held0
+ do_item_unlink(it); /
* MTSAFE - cache_lock held */0
@@ -412,7 +412,7 @@ item *item_get(const char *key, const size_t nkey) {
0
return item_get_notedeleted(key, nkey, 0);
0
-/*
returns an item whether or not it's delete-locked or expired. */
0
+/*
* returns an item whether or not it's delete-locked or expired. */
0
item *do_item_get_nocheck(const char *key, const size_t nkey) {
0
item *it = assoc_find(key, nkey);
Comments
No one has commented yet.