Solved a data race I found while using the library in a concurrent context.