cpp-lru-cache icon indicating copy to clipboard operation
cpp-lru-cache copied to clipboard

Thread-safety

Open knedlsepp opened this issue 8 years ago • 3 comments

After a quick test using valgrind I'm experiencing invalid reads on a multithreaded application. Is this a bug or is your library only expected to work in a single-threaded environment?

knedlsepp avatar Feb 03 '17 10:02 knedlsepp

@knedlsepp the library is not thread safe, you should use locking mechanisms to use it in a multi-threaded environment. Probably it should be better documented.

lamerman avatar Feb 06 '17 10:02 lamerman

Oh that's unfortunate. Thank you for the information!

knedlsepp avatar Feb 06 '17 12:02 knedlsepp