libCom/errlog: Clean up possible problem at shutdown.
Don't use epicsMutexMustLock() in msgbufGetFree(). When we're shutting down, the pvtData.msgQueueLock gets destroyed. This makes msgbufGetFree() return NULL if the lock is dead. The epicsMutexMustLock() routine asserts(), which recurses...
This commit is contained in:
1 parent
fb493a064c
commit
c503a03f37
1 file changed
+3
-1
@@ -552,7 +552,9 @@ static char *msgbufGetFree(int noConsoleMessage)
|
||||
{
|
||||
msgNode *pnextSend;
|
||||
|
||||
epicsMutexMustLock(pvtData.msgQueueLock);
|
||||
if (epicsMutexLock(pvtData.msgQueueLock) != epicsMutexLockOK)
|
||||
return 0;
|
||||
|
||||
if ((ellCount(&pvtData.msgQueue) == 0) && pvtData.missedMessages) {
|
||||
int nchar;
|
||||
|
||||
|
||||
Reference in new issue
Block a user