+
+ void OnDataReady()
+ {
+ recvq.clear();
+ parent->OnNotify();
+ }
+
+ void OnError(BufferedSocketError)
+ {
+ ServerInstance->GlobalCulls.AddItem(this);
+ }
+};
+
+SocketThread::SocketThread()
+{
+ int fds[2];
+ if (pipe(fds))
+ throw new CoreException("Could not create pipe " + std::string(strerror(errno)));
+ signal.sock = new ThreadSignalSocket(this, fds[0], fds[1]);