www.pudn.com > DVBPlayer.rar > thread.cpp, change:2004-07-15,size:783b


 
#include "config.h" 
#include "thread.h" 
 
#if defined(__LINUX__) || defined(solaris) || defined(__FreeBSD__) || \ 
    defined(__QNX__) || defined(irix) 
    #include "pthreadthread.h" 
#elif WIN32 
    #include "win32thread.h" 
#elif defined(__BEOS__) 
    #include "beosthread.h" 
#else 
    #error thread class needs to be defined for this platform 
#endif 
 
Thread* Thread::CreateThread() 
{ 
    Thread* thread = NULL; 
#if defined(__LINUX__) || defined(solaris) || defined(__FreeBSD__) || \ 
    defined(__QNX__) || defined(irix) 
    thread = new pthreadThread(); 
#elif WIN32 
    thread = new win32Thread(); 
#elif defined(__BEOS__) 
    thread = new beosThread(); 
#else 
    #error thread class needs to be defined for this platform 
#endif 
 
    return thread; 
}