Merge branch 'urcu/ht' into urcu/ht-benchmarks
[urcu.git] / rculfhash.c
index cc8b22d68083f4f313efd6238acf81d74121135f..0796f376e06ce63e3bd3ad4e3c33d7297d904b7e 100644 (file)
@@ -635,7 +635,7 @@ struct cds_lfht *cds_lfht_new(cds_lfht_hash_fct hash_fct,
        unsigned long order;
 
        /* init_size must be power of two */
-       if (init_size & (init_size - 1))
+       if (init_size && (init_size & (init_size - 1)))
                return NULL;
        ht = calloc(1, sizeof(struct cds_lfht));
        ht->hash_fct = hash_fct;
This page took 0.022595 seconds and 4 git commands to generate.