def acquire_reader(self):
with self.mutex:<EOL><INDENT>while self.rwlock < <NUM_LIT:0> or self.rwlock == self.max_reader_concurrency or self.writers_waiting:<EOL><INDENT>self.readers_ok.wait()<EOL><DEDENT>self.rwlock += <NUM_LIT:1><EOL><DEDENT>
Acquire a read lock, several threads can hold this type of lock.