fix potential deadlock between multithreaded fork and aio