remove debug
[enigma2.git] / lib / base / thread.h
index dad80424b526571efc72ecace1848fdc769457a8..12c5b25cbaba0c1c72f4e4ea9549d2320b9f566c 100644 (file)
@@ -29,6 +29,11 @@ public:
        eThread();
        virtual ~eThread();
 
+               /* thread_finished is called from within the thread context as the last function
+                  before the thread is going to die.
+                  It should be used to do final cleanups (unlock locked mutexes ....) */
+       virtual void thread_finished() {}
+
                /* runAsync starts the thread.
                   it assumes that the thread is not running,
                   i.e. sync() *must* return 0.
@@ -46,7 +51,7 @@ public:
                /* result: 0 - thread is not alive
                           1 - thread state unknown */
        int sync();
-       void sendSignal(int sig);
+       int sendSignal(int sig);
 
                /* join the thread, i.e. busywait until thread has finnished. */
        void kill(bool sendcancel=false);