diff options
author | David Bohman <debohman@gmail.com> | 2022-10-13 17:08:25 -0700 |
---|---|---|
committer | dormando <dormando@rydia.net> | 2022-10-20 14:46:00 -0700 |
commit | f34a2b68cdec7fc638b125757d8ff7dd8f150c34 (patch) | |
tree | e09dd099aae3b336502b1380188c8d56e134af88 /assoc.c | |
parent | e2d62c6589ea9b94cb66df57c6d08eb346c4b8c4 (diff) | |
download | memcached-f34a2b68cdec7fc638b125757d8ff7dd8f150c34.tar.gz |
Fixes to build with clang-15:
Fix unused variable error when dtrace is not enabled.
Add void parameter declaration for drop_privileges() in darwin_priv.c.
Diffstat (limited to 'assoc.c')
-rw-r--r-- | assoc.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -80,14 +80,18 @@ item *assoc_find(const char *key, const size_t nkey, const uint32_t hv) { } item *ret = NULL; +#ifdef ENABLE_DTRACE int depth = 0; +#endif while (it) { if ((nkey == it->nkey) && (memcmp(key, ITEM_key(it), nkey) == 0)) { ret = it; break; } it = it->h_next; +#ifdef ENABLE_DTRACE ++depth; +#endif } MEMCACHED_ASSOC_FIND(key, nkey, depth); return ret; |