]> git.sur5r.net Git - bacula/bacula/commitdiff
Fix messages segfault
authorEric Bollengier <eric@baculasystems.com>
Tue, 16 Oct 2012 07:00:20 +0000 (09:00 +0200)
committerKern Sibbald <kern@sibbald.com>
Sat, 20 Apr 2013 12:51:02 +0000 (14:51 +0200)
bacula/src/lib/message.c

index 2a67c78ea6d35f48ca49b0d5bf4fabde5df9b49c..e2fd3e416bba31e295995a93a362c91e33e33ebd 100644 (file)
@@ -130,7 +130,7 @@ void MSGS::unlock()
 void MSGS::wait_not_in_use()     /* leaves fides_mutex set */
 {
    lock();
-   while (m_in_use) {
+   while (m_in_use || m_closing) {
       unlock();
       bmicrosleep(0, 200);         /* wait */
       lock();