Ignore:
Timestamp:
Aug 1, 2007, 12:40:49 AM (14 years ago)
Author:
charles
Message:

More Win32 portability changes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libtransmission/net.c

    r2576 r2578  
    241241static int makeSocketNonBlocking( int s )
    242242{
    243     int flags;
    244 
    245 #ifdef SYS_BEOS
    246     flags = 1;
     243#ifdef SYS_WIN32
     244    unsigned long flags = 1;
     245    if( ioctlsocket( sock, FIONBIO, &flags) == SOCKET_ERROR )
     246#elif defined(SYS_BEOS)
     247    int flags = 1;
    247248    if( setsockopt( s, SOL_SOCKET, SO_NONBLOCK,
    248249                    &flags, sizeof( int ) ) < 0 )
    249250#else
     251    int flags = 1;
    250252    if( ( flags = fcntl( s, F_GETFL, 0 ) ) < 0 ||
    251253        fcntl( s, F_SETFL, flags | O_NONBLOCK ) < 0 )
Note: See TracChangeset for help on using the changeset viewer.