All pastes #807546 Raw Edit

Miscellany

public cpp v1 · immutable
·published 2007-12-06 20:13 UTC
rendered paste body
main.cpp#include <boost/thread.hpp>#include <boost/bind.hpp>#include <stdlib.h>#include <iostream>#include "server.hpp"int main(int argc, char* argv[]) {	boost::thread listenThread(boost::bind(localLoop, 90));	listenThread.join();	while (1) {		if ( std::cin.get() ) {			break;		}		Sleep(1000);	}	return 0;}server.hppextern void localLoop(int port);server.cpp#include <boost/thread.hpp>#include <boost/bind.hpp>#include "asio.hpp"#include <fstream>#include <stdlib.h>#include <string>#include <iostream>void loopLocal(int port) {	while ( true ) {		std::cout << "I'M SPINNING!" << std::endl;	}}