From: Mathieu Desnoyers Date: Sun, 9 Jun 2013 21:05:06 +0000 (-0400) Subject: rcuja: fix below/above "or equal" lookup X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=b1588aebcd1494f5c36ad13bdaddb426f018ddbe;p=urcu.git rcuja: fix below/above "or equal" lookup "or equal" was missing for 0 et max value. Signed-off-by: Mathieu Desnoyers --- diff --git a/rcuja/rcuja.c b/rcuja/rcuja.c index a16385b..a791d5b 100644 --- a/rcuja/rcuja.c +++ b/rcuja/rcuja.c @@ -1820,11 +1820,11 @@ struct cds_ja_node *cds_ja_lookup_inequality(struct cds_ja *ja, uint64_t key, switch (mode) { case JA_LOOKUP_BE: - if (caa_unlikely(key > ja->key_max || key == 0)) + if (caa_unlikely(key > ja->key_max)) return NULL; break; case JA_LOOKUP_AE: - if (caa_unlikely(key >= ja->key_max)) + if (caa_unlikely(key > ja->key_max)) return NULL; break; default: