/[svn]/liblscp/trunk/src/thread.c
ViewVC logotype

Diff of /liblscp/trunk/src/thread.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 100 by capela, Tue Jun 1 20:27:25 2004 UTC revision 179 by capela, Tue Jul 6 16:24:41 2004 UTC
# Line 142  lscp_status_t lscp_thread_cancel ( lscp_ Line 142  lscp_status_t lscp_thread_cancel ( lscp_
142  //  fprintf(stderr, "lscp_thread_cancel: pThread=%p.\n", pThread);  //  fprintf(stderr, "lscp_thread_cancel: pThread=%p.\n", pThread);
143    
144  #if defined(WIN32)  #if defined(WIN32)
145      if (pThread->hThread && TerminateThread(pThread->hThread, 0)) {      if (pThread->hThread) { // Should we TerminateThread(pThread->hThread, 0) ?
146          pThread->hThread = NULL;      /*  pThread->hThread = NULL; */
147          ret = LSCP_OK;          ret = LSCP_OK;
148      }      }
149  #else  #else
# Line 163  lscp_status_t lscp_thread_destroy ( lscp Line 163  lscp_status_t lscp_thread_destroy ( lscp
163    
164      if (ret == LSCP_OK)      if (ret == LSCP_OK)
165          ret = lscp_thread_join(pThread);          ret = lscp_thread_join(pThread);
166            
167  //  fprintf(stderr, "lscp_thread_destroy: pThread=%p.\n", pThread);  //  fprintf(stderr, "lscp_thread_destroy: pThread=%p.\n", pThread);
168    
169      free(pThread);      if (ret == LSCP_OK)
170            free(pThread);
171    
172      return ret;      return ret;
173  }  }

Legend:
Removed from v.100  
changed lines
  Added in v.179

  ViewVC Help
Powered by ViewVC