Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Nov 29, 2007, 6:13:47 PM (18 years ago)
Author:
landauf
Message:

changed retos usleep hack to a more generic solution:
#ifdef WIN32
#include <windows.h>
#define usleep(x) Sleep((x)/1000)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/FICN/src/network/dummyclient.cc

    r346 r355  
    88#include <enet/enet.h>
    99#include "PacketManager.h"
    10 
    11 // workaround for usleep(int) under windows
    12 #ifdef WIN32
    13 #include "winbase.h"
    14 #endif
    1510
    1611
     
    7368      cout << "failed sending" << endl;
    7469    }
    75 // under windows, use Sleep(milliseconds) instead of usleep(microseconds)
    76 #ifdef WIN32
    77     Sleep(1000);
    78 #else
    7970    usleep(1000000);
    80 #endif
    8171  }
    8272
Note: See TracChangeset for help on using the changeset viewer.