Ignore:
Timestamp:
Oct 13, 2001, 8:51:08 PM (24 years ago)
Author:
sandervl
Message:

several updates + fixes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wsock32/asyncthread.cpp

    r6201 r7041  
    1 /* $Id: asyncthread.cpp,v 1.11 2001-07-07 14:29:40 achimha Exp $ */
     1/* $Id: asyncthread.cpp,v 1.12 2001-10-13 18:51:07 sandervl Exp $ */
    22
    33/*
     
    4040////    WSASetBlocking(FALSE, pThreadParm->hThread);
    4141
     42  dprintf(("AsyncThread %x exit", pThreadParm->hAsyncTaskHandle));
    4243  free((PVOID)pThreadParm);
    4344}
     
    109110   memset(pThreadParm, 0, sizeof(*pThreadParm));
    110111   asyncThreadMutex.leave();
     112}
     113//******************************************************************************
     114//******************************************************************************
     115void WSACancelAllAsyncRequests()
     116{
     117 PASYNCTHREADPARM pThreadInfo;
     118 BOOL             found = FALSE;
     119
     120   dprintf(("WSACancelAllAsyncRequests"));
     121   asyncThreadMutex.enter();
     122   pThreadInfo = threadList;
     123
     124   while(pThreadInfo) {
     125        dprintf(("WSACancelAllAsyncRequests %x", pThreadInfo->hAsyncTaskHandle));
     126        pThreadInfo->fCancelled = TRUE;
     127        pThreadInfo->u.asyncselect.asyncSem->post();
     128        pThreadInfo = pThreadInfo->next;
     129   }
     130   asyncThreadMutex.leave();
     131   //TODO: not the right way to wait for the async threads to die
     132   DosSleep(250);
    111133}
    112134//******************************************************************************
Note: See TracChangeset for help on using the changeset viewer.