Fix: Use %lu rather than %ld to print count
authoryaowenbin1 <yaowenbin1@huawei.com>
Thu, 9 Jun 2022 03:08:25 +0000 (11:08 +0800)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Thu, 9 Jun 2022 17:53:28 +0000 (13:53 -0400)
In ht_count_del function, the type of count variable is defined as unsigned long,
so use %lu rather than %ld to print it.

Signed-off-by: yaowenbin1 <yaowenbin1@huawei.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: Ie2701fa0a8170b05532429b34e0f798e6f27139b

src/rculfhash.c

index 8046f3a63a280397be3986231f1db8921ea4bfdb..872d6ff1dea4d1a8533f5bc0c3ba70fe0a438db3 100644 (file)
@@ -763,7 +763,7 @@ void ht_count_del(struct cds_lfht *ht, unsigned long size, unsigned long hash)
 
        if ((count >> CHAIN_LEN_RESIZE_THRESHOLD) >= size)
                return;
 
        if ((count >> CHAIN_LEN_RESIZE_THRESHOLD) >= size)
                return;
-       dbg_printf("del set global %ld\n", count);
+       dbg_printf("del set global %lu\n", count);
        /*
         * Don't shrink table if the number of nodes is below a
         * certain threshold.
        /*
         * Don't shrink table if the number of nodes is below a
         * certain threshold.
This page took 0.026233 seconds and 4 git commands to generate.