*** VERSION 5.3.0 ***
[NeonServV5.git] / src / ClientSocket.h
index 1ef009c148471a8d3395c98a52a3c163ee962a78..9bcdaffccd3aa2b0c1117e5fd4b1df588682ecc0 100644 (file)
@@ -1,4 +1,4 @@
-/* ClientSocket.h - NeonServ v5.2
+/* ClientSocket.h - NeonServ v5.3
  * Copyright (C) 2011  Philipp Kreil (pk910)
  * 
  * This program is free software: you can redistribute it and/or modify
@@ -26,6 +26,7 @@
 #define SOCKET_FLAG_USE_QUEUE 0x10
 #define SOCKET_FLAG_RECONNECT 0x20
 #define SOCKET_FLAG_SSL       0x40
+#define SOCKET_FLAG_HAVE_SSL  0x80
 
 #define BUF_SIZ 512
 
@@ -40,6 +41,7 @@ struct ClientSocket {
     unsigned int bufferpos;
     char *host;
     int port;
+    char *bind;
     char *pass;
     char *nick;
     char *ident;
@@ -64,9 +66,10 @@ struct ClientSocket {
     struct ClientSocket *next;
 };
 
-struct ClientSocket* create_socket(char *host, int port, char *pass, char *nick, char *ident, char *realname);
+struct ClientSocket* create_socket(char *host, int port, char *bindto, char *pass, char *nick, char *ident, char *realname);
 int connect_socket(struct ClientSocket *client);
 int close_socket(struct ClientSocket *client);
+int disconnect_socket(struct ClientSocket *client);
 int write_socket_force(struct ClientSocket *client, char* msg, int len);
 int write_socket(struct ClientSocket *client, char* msg, int len);
 void socket_loop(int timeout_seconds);