fixed some more coding fails
[NeonServV5.git] / src / ClientSocket.c
index 13f8b6b6d55f82b9debe72288f0422f35694f197..cb40cc7dc9eb1afe311919d685ca16de153846e7 100644 (file)
@@ -61,6 +61,8 @@ void init_sockets() {
 }
 
 struct ClientSocket* create_socket(char *host, int port, char *bindto, char *pass, char *nick, char *ident, char *realname) {
+    if(!sockets)
+        init_sockets();
     struct ClientSocket *client = malloc(sizeof(*client));
     if (!client) {
         return NULL;