* ---------------------------------------------------
*/
+#include "inspircd.h"
#include <string>
#include "configreader.h"
#include "socket.h"
-#include "inspircd.h"
#include "socketengine.h"
#include "wildcard.h"
void irc::sockets::Blocking(int s)
{
#ifndef WIN32
- int flags = fcntl(s, F_GETFL, 0);
+ int flags = fcntl(s, F_GETFL, 0);
fcntl(s, F_SETFL, flags ^ O_NONBLOCK);
#else
- unsigned long opt = 0;
- ioctlsocket(s, FIONBIO, &opt);
+ unsigned long opt = 0;
+ ioctlsocket(s, FIONBIO, &opt);
#endif
}
void irc::sockets::NonBlocking(int s)
{
#ifndef WIN32
- int flags = fcntl(s, F_GETFL, 0);
+ int flags = fcntl(s, F_GETFL, 0);
fcntl(s, F_SETFL, flags | O_NONBLOCK);
#else
- unsigned long opt = 1;
- ioctlsocket(s, FIONBIO, &opt);
+ unsigned long opt = 1;
+ ioctlsocket(s, FIONBIO, &opt);
#endif
}