git-svn-id: svn://db.shs.com.ru/pip@717 12ceb7fc-bf1f-11e4-8940-5bc7170c53b5

This commit is contained in:
2019-02-07 15:25:36 +00:00
parent 90423ebdce
commit 06150591fc

View File

@@ -189,6 +189,7 @@ PIThread::~PIThread() {
if (!running_ || PRIVATE->thread == 0) return; if (!running_ || PRIVATE->thread == 0) return;
#ifdef FREERTOS #ifdef FREERTOS
//void * ret(0); //void * ret(0);
piCout << "~PIThread" << PRIVATE->thread;
piCout << pthread_join(PRIVATE->thread, 0); piCout << pthread_join(PRIVATE->thread, 0);
piCout << "FREERTOS can't join pthreads!"; piCout << "FREERTOS can't join pthreads!";
#else #else
@@ -219,7 +220,7 @@ bool PIThread::start(int timer_delay) {
# endif # endif
pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_DETACHED); pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_DETACHED);
int ret = pthread_create(&PRIVATE->thread, &attr, thread_function, this); int ret = pthread_create(&PRIVATE->thread, &attr, thread_function, this);
//piCout << "pthread_create" << PRIVATE->thread; piCout << "pthread_create" << PRIVATE->thread;
pthread_attr_destroy(&attr); pthread_attr_destroy(&attr);
if (ret == 0) { if (ret == 0) {
# ifdef MAC_OS # ifdef MAC_OS