deque<string> waitingTiles;
typedef map<string,time_t> CompletedTiles;
CompletedTiles completedTiles;
-netSocket socket;
+netSocket theSocket;
#ifdef HAVE_SVN_CLIENT_H
write(1, msg, sizeof(msg) - 1);
terminating = true;
signal(param, prior_signal_handlers[param]);
- socket.close();
+ theSocket.close();
}
// Must call this before any other net stuff
netInit( &argc,argv );
- if ( ! socket.open( false ) ) { // open a UDP socket
+ if ( ! theSocket.open( false ) ) { // open a UDP socket
printf("error opening socket\n");
return -1;
}
- if ( socket.bind( host, port ) == -1 ) {
+ if ( theSocket.bind( host, port ) == -1 ) {
printf("error binding to port %d\n", port);
return -1;
}
if (verbose && waitingTiles.empty()) {
cout << "Idle; waiting for FlightGear position\n";
}
- socket.setBlocking(waitingTiles.empty());
- len = socket.recv(msg, maxlen, 0);
+ theSocket.setBlocking(waitingTiles.empty());
+ len = theSocket.recv(msg, maxlen, 0);
if (len >= 0) {
msg[len] = '\0';
recv_msg = true;