X-Git-Url: http://git.liburcu.org/?p=urcu.git;a=blobdiff_plain;f=urcu.c;h=b8567555d09ecbb22547aa6f236392d439eea871;hp=a3ceca3f5263be7812288f4e909eed6878246980;hb=7a5a38f52b8814d0188b74a91cb635bc205df96c;hpb=0d342f2fb06c0b2e37a34b0968d1dc26e2220825 diff --git a/urcu.c b/urcu.c index a3ceca3..b856755 100644 --- a/urcu.c +++ b/urcu.c @@ -233,7 +233,7 @@ void update_counter_and_wait(void) } list_for_each_entry_safe(index, tmp, ®istry, head) { - if (!rcu_old_gp_ongoing(&index->ctr)) + if (!rcu_gp_ongoing(&index->ctr)) list_move(&index->head, &qsreaders); } @@ -346,7 +346,7 @@ void rcu_register_thread(void) { rcu_reader.tid = pthread_self(); assert(rcu_reader.need_mb == 0); - assert(rcu_reader.ctr == 0); + assert(!(rcu_reader.ctr & RCU_GP_CTR_NEST_MASK)); mutex_lock(&rcu_gp_lock); rcu_init(); /* In case gcc does not support constructor attribute */