VirtualBox

Changeset 14181 in vbox for trunk/src/VBox/Devices/Network


Ignore:
Timestamp:
Nov 13, 2008 3:49:43 PM (16 years ago)
Author:
vboxsync
Message:

get rid of cMaxEvens and initializing loop for two events array

Location:
trunk/src/VBox/Devices/Network/slirp
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Network/slirp/slirp.c

    r14180 r14181  
    226226    }
    227227#ifdef VBOX_WITH_SIMPLEFIED_SLIRP_SYNC
    228     pData->cMaxEvent = VBOX_EVENT_COUNT;
    229     pData->phEvents = malloc(sizeof(HANDLE) * pData->cMaxEvent);
    230     for (i = 1; i < WSA_MAXIMUM_WAIT_EVENTS; ++i) {
    231             pData->phEvents[i] = CreateEvent(NULL, FALSE, FALSE, NULL);
    232     }
     228        pData->phEvents[0] = CreateEvent(NULL, FALSE, FALSE, NULL);
     229        pData->phEvents[VBOX_SOCKET_EVENT_INDEX] = CreateEvent(NULL, FALSE, FALSE, NULL);
    233230#endif
    234231#endif
  • trunk/src/VBox/Devices/Network/slirp/slirp_state.h

    r14180 r14181  
    120120#define VBOX_SOCKET_EVENT (pData->phEvents[VBOX_SOCKET_EVENT_INDEX])
    121121#define VBOX_EVENT_COUNT 2
    122     int cMaxEvent;
    123122    HANDLE *phEvents;
    124123#endif
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette