#include STL_STRING
-#include <simgear/math/fg_types.hxx>
-
-#include "iochannel.hxx"
+#include <simgear/math/sg_types.hxx>
+#include <simgear/io/iochannel.hxx>
FG_USING_STD(string);
int save_len;
SocketType sock;
+ SocketType msgsock;
short unsigned int port;
int sock_style; // SOCK_STREAM or SOCK_DGRAM
+ bool first_read;
+
// make a server (master listening) socket
SocketType make_server_socket();
// If specified as a server (in direction for now) open the master
// listening socket. If specified as a client (out direction),
// open a connection to a server.
- bool open( SGProtocolDir dir );
+ bool open( const SGProtocolDir d );
// read data from socket
int read( char *buf, int length );
int readline( char *buf, int length );
// write data to a socket
- int write( char *buf, int length );
+ int write( const char *buf, const int length );
// write null terminated string to a socket
- int writestring( char *str );
+ int writestring( const char *str );
// close file
bool close();