We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9d635fa commit d8b1047Copy full SHA for d8b1047
items.c
@@ -769,9 +769,6 @@ static void *item_crawler_thread(void *arg) {
769
fprintf(stderr, "Starting LRU crawler background thread\n");
770
while (do_run_lru_crawler_thread) {
771
pthread_cond_wait(&lru_crawler_cond, &lru_crawler_lock);
772
- STATS_LOCK();
773
- stats.lru_crawler_running = true;
774
- STATS_UNLOCK();
775
776
while (crawler_count) {
777
item *search = NULL;
@@ -918,6 +915,9 @@ enum crawler_result_type lru_crawler_crawl(char *slabs) {
918
915
}
919
916
pthread_mutex_unlock(&cache_lock);
920
917
pthread_cond_signal(&lru_crawler_cond);
+ STATS_LOCK();
+ stats.lru_crawler_running = true;
+ STATS_UNLOCK();
921
pthread_mutex_unlock(&lru_crawler_lock);
922
return CRAWLER_OK;
923
0 commit comments