chenBright commented on PR #3053:
URL: https://github.com/apache/brpc/pull/3053#issuecomment-3182592138
```shell
bthread1 bthread2
bthread_sem_timedwait
rwlock->reader_count->fetch_add(RWLockMaxReaders);
bthread_sem_post_n
bthread_mutex_unlock
rwlock->reader_count->fetch_add
```
In this case, `reader_sema` has been posted. Subsequently, there may be a
problem where the write lock and read lock enter the critical section at the
same time.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]