don't kill if thread isn't alive
authorFelix Domke <tmbinc@elitedvb.net>
Fri, 20 Jan 2006 00:30:10 +0000 (00:30 +0000)
committerFelix Domke <tmbinc@elitedvb.net>
Fri, 20 Jan 2006 00:30:10 +0000 (00:30 +0000)
lib/base/filepush.cpp

index 39319a2477b056003b2729155890d40519ac44e2..60dc78ee2995829c3de7f9ccd6156d7a567fc3c2 100644 (file)
@@ -111,6 +111,8 @@ void eFilePushThread::start(int fd_source, int fd_dest)
 
 void eFilePushThread::stop()
 {
 
 void eFilePushThread::stop()
 {
+       if (!thread_running()) /* FIXME: races */
+               return;
        m_stop = 1;
        sendSignal(SIGUSR1);
        kill();
        m_stop = 1;
        sendSignal(SIGUSR1);
        kill();