X-Git-Url: http://git.liburcu.org/?a=blobdiff_plain;f=rculfhash.c;fp=rculfhash.c;h=c1ff314bc0d5cc748e1329d8508f72641ae804ad;hb=feda272217fca3604e904b83845814223b877287;hp=1eda2dd858981477041fcdcee252c78d224127c2;hpb=2e79c44597547799d9501940b660f676a559b738;p=urcu.git diff --git a/rculfhash.c b/rculfhash.c index 1eda2dd..c1ff314 100644 --- a/rculfhash.c +++ b/rculfhash.c @@ -779,9 +779,9 @@ int _cds_lfht_replace(struct cds_lfht *ht, unsigned long size, */ return -ENOENT; } - assert(!is_bucket(old_next)); - assert(new_node != clear_flag(old_next)); - new_node->next = clear_flag(old_next); + assert(old_next == clear_flag(old_next)); + assert(new_node != old_next); + new_node->next = old_next; /* * Here is the whole trick for lock-free replace: we add * the replacement node _after_ the node we want to