You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We’ve found a bug that’s can cause a segfault in MOOSDB, I've attached a patch for a fix as .txt files as that's what's supported for upload. There are possible performance implications with our patch, as we're now mutex locking ProcessClient which may have been concurrent before, and now is more sequential. This can only be avoided with C+17 shared_lock or some complicated back-port of that to C++11 ( our compiler standard).
The bug ultimately caused a segfault in MOOSDB at ThreadedCommServer.cpp#388:
Adding to m_ClientThreads needs to be mutually exclusive with any other operation on the map and needs guarding with a mutex (only with the Add though, multiple Reads can happen at once).
I should add, I don’t think the performance impact will be big, if at all. I’m not even sure how often ProcessClient is called simultaneously and even if it is, we’ve been careful not to hold the mutex longer than needed. Just thought I should point out the fact there is now a mutex in there that could have an impact.
We’ve found a bug that’s can cause a segfault in MOOSDB, I've attached a patch for a fix as .txt files as that's what's supported for upload. There are possible performance implications with our patch, as we're now mutex locking ProcessClient which may have been concurrent before, and now is more sequential. This can only be avoided with C+17 shared_lock or some complicated back-port of that to C++11 ( our compiler standard).
The bug ultimately caused a segfault in MOOSDB at ThreadedCommServer.cpp#388:
because pClient is null/uninitialised. This is caused by a race condition with:
Adding to m_ClientThreads needs to be mutually exclusive with any other operation on the map and needs guarding with a mutex (only with the Add though, multiple Reads can happen at once).
ThreadedCommServer.cpp.txt
ThreadedCommServer.h.txt
The text was updated successfully, but these errors were encountered: