mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-25 09:11:06 -04:00
Changes required to get Retroshare V0.4 working under windows.
Most of these changes relate to: (1) rand() is different (2) sleep() don't exist on Windows. (3) networking headers are different - these need to be cleaned up in general. (4) disabled tests that won't compile on Windows. Will probably have to rollback some of these changes for Unix later. git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@372 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
9e954e9c0f
commit
9bdd44d0f5
29 changed files with 218 additions and 86 deletions
|
@ -3,6 +3,8 @@
|
|||
/***** Test for the new DHT system *****/
|
||||
|
||||
|
||||
#include "pqi/pqinetwork.h"
|
||||
|
||||
#include "util/rsnet.h"
|
||||
#include "util/rsthreads.h"
|
||||
#include "util/rsprint.h"
|
||||
|
@ -218,7 +220,13 @@ int main()
|
|||
dhtTester.start();
|
||||
|
||||
/* wait for a little before switching on */
|
||||
/********************************** WINDOWS/UNIX SPECIFIC PART ******************/
|
||||
#ifndef WINDOWS_SYS
|
||||
sleep(1);
|
||||
#else
|
||||
Sleep(1000);
|
||||
#endif
|
||||
/********************************** WINDOWS/UNIX SPECIFIC PART ******************/
|
||||
|
||||
std::cerr << "Switching on DhtTester()" << std::endl;
|
||||
dhtTester.setDhtOn(true);
|
||||
|
@ -234,7 +242,14 @@ int main()
|
|||
while(1)
|
||||
{
|
||||
std::cerr << "Main waiting..." << std::endl;
|
||||
/********************************** WINDOWS/UNIX SPECIFIC PART ******************/
|
||||
#ifndef WINDOWS_SYS
|
||||
sleep(3);
|
||||
#else
|
||||
Sleep(3000);
|
||||
#endif
|
||||
/********************************** WINDOWS/UNIX SPECIFIC PART ******************/
|
||||
|
||||
|
||||
/* handle async search */
|
||||
frmMtx.lock(); /* LOCK TEST FRAMEWORK MUTEX */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue