Ignore:
Timestamp:
Feb 20, 2002, 4:07:14 PM (24 years ago)
Author:
sandervl
Message:

accept bugfix for changing async request

File:
1 edited

Legend:

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

    r7805 r7977  
    1 /* $Id: wsock32.cpp,v 1.46 2002-02-06 10:33:56 sandervl Exp $ */
     1/* $Id: wsock32.cpp,v 1.47 2002-02-20 15:07:14 sandervl Exp $ */
    22
    33/*
     
    376376   //to blocking mode
    377377   if (cmd == FIONBIO) {
    378         HWND  hwnd;
    379         int   msg;
     378        ULONG ulNotifyHandle, ulNotifyData;
     379        int   mode;
    380380        ULONG lEvent;
    381381
    382         if(QueryAsyncEvent(s, &hwnd, &msg, &lEvent) == TRUE) {
     382        if(QueryAsyncEvent(s, &mode, &ulNotifyHandle, &ulNotifyData, &lEvent) == TRUE)
     383        {
    383384                if(*argp != 0) {
    384385                        //nothing to do; already non-blocking
     
    521522                                int *,            addrlen)
    522523{
    523  int   ret, msg;
    524  HWND  hwnd;
    525  ULONG lEvent;
     524 int   ret, mode;
     525 ULONG lEvent, notifyData, notifyHandle;
    526526
    527527   if(!fWSAInitialized) {
     
    549549        //if this socket has an active async. select pending, then call WSAAsyncSelect
    550550        //with the same parameters for the new socket (see docs)
    551         if(QueryAsyncEvent(s, &hwnd, &msg, &lEvent) == TRUE) {
    552                 if(WSAAsyncSelect(ret, hwnd, msg, lEvent) == SOCKET_ERROR) {
     551        if(QueryAsyncEvent(s, &mode, &notifyHandle, &notifyData, &lEvent) == TRUE) {
     552                if(WSAAsyncSelectWorker(s, mode, notifyHandle, notifyData, lEvent) == SOCKET_ERROR) {
    553553                        ret = SOCKET_ERROR;
    554554                }
     
    948948  struct ws_linger *yy;
    949949  struct linger     xx;
    950   int               ret;
     950  int               ret, val;
    951951  ULONG             size;
    952952  char             *safeoptval;
     
    11591159                   return SOCKET_ERROR;
    11601160               }
    1161                dprintf(("IPPROTO_IP, IP_HDRINCL 0x%x", *optval));
    1162                ret = setsockopt(s, IPPROTO_IP, IP_HDRINCL_OS2, (char *)optval, optlen);
     1161               val = *optval;
     1162               dprintf(("IPPROTO_IP, IP_HDRINCL 0x%x", val));
     1163               ret = setsockopt(s, IPPROTO_IP, IP_HDRINCL_OS2, (char *)&val, optlen);
    11631164               break;
    11641165
Note: See TracChangeset for help on using the changeset viewer.