Version 0.8.11
[userspace-rcu.git] / rculfhash.c
index 57f1a04d46dd3d446ca88fa74267660dd7a26fe2..242a46702e1150c9d5c446c056c50daec243df41 100644 (file)
 #include <stdint.h>
 #include <string.h>
 #include <sched.h>
+#include <unistd.h>
 
 #include "config.h"
-#include <urcu.h>
+#include <urcu-pointer.h>
 #include <urcu-call-rcu.h>
 #include <urcu-flavor.h>
 #include <urcu/arch.h>
@@ -1386,7 +1387,7 @@ void fini_table(struct cds_lfht *ht,
                unsigned long len;
 
                len = 1UL << (i - 1);
-               dbg_printf("fini order %lu len: %lu\n", i, len);
+               dbg_printf("fini order %ld len: %lu\n", i, len);
 
                /* Stop shrink if the resize target changes under us */
                if (CMM_LOAD_SHARED(ht->resize_target) > (1UL << (i - 1)))
@@ -1805,6 +1806,9 @@ int cds_lfht_destroy(struct cds_lfht *ht, pthread_attr_t **attr)
        free_split_items_count(ht);
        if (attr)
                *attr = ht->resize_attr;
+       ret = pthread_mutex_destroy(&ht->resize_mutex);
+       if (ret)
+               ret = -EBUSY;
        poison_free(ht);
 end:
        return ret;
This page took 0.022583 seconds and 4 git commands to generate.