diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2005-12-14 18:04:30 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2005-12-14 18:04:30 +0000 |
commit | d3c5c8cfa2cd8c9dfd83e22f35702f5fb7d9f7ac (patch) | |
tree | cdab0430377f181dcc8d8a5744dde5913a92cd75 | |
parent | 665d01855ea1b54e48c0acdf9db44a8dbf0f3dc6 (diff) |
Fixups
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2432 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r-- | include/inspircd_io.h | 2 | ||||
-rw-r--r-- | src/inspircd.cpp | 2 | ||||
-rw-r--r-- | src/inspircd_io.cpp | 7 |
3 files changed, 6 insertions, 5 deletions
diff --git a/include/inspircd_io.h b/include/inspircd_io.h index f07666747..19338e54b 100644 --- a/include/inspircd_io.h +++ b/include/inspircd_io.h @@ -248,7 +248,7 @@ class ServerConfig : public classbase /** A list of ports which the server is listening on */ - int ports[MAXSOCKS]; + int ports[255]; ServerConfig(); diff --git a/src/inspircd.cpp b/src/inspircd.cpp index cc4964ca8..956dda1f0 100644 --- a/src/inspircd.cpp +++ b/src/inspircd.cpp @@ -74,7 +74,7 @@ std::vector<InspSocket*> module_sockets; extern int MODCOUNT; int openSockfd[MAXSOCKS]; -struct sockaddr_in client,server; +sockaddr_in client,server; socklen_t length; extern InspSocket* socket_ref[65535]; diff --git a/src/inspircd_io.cpp b/src/inspircd_io.cpp index 2b5a880cb..a033f0df6 100644 --- a/src/inspircd_io.cpp +++ b/src/inspircd_io.cpp @@ -1027,6 +1027,7 @@ int OpenTCPSocket (void) int BindPorts() { char configToken[MAXBUF], Addr[MAXBUF], Type[MAXBUF]; + sockaddr_in client,server; int clientportcount = 0; for (int count = 0; count < Config->ConfValueEnum("bind",&Config->config_f); count++) { @@ -1043,9 +1044,9 @@ int BindPorts() log(DEBUG,"InspIRCd: startup: read binding %s:%s [%s] from config",Addr,configToken, Type); } } - portCount = clientportcount; + int PortCount = clientportcount; - for (int count = 0; count < portCount; count++) + for (int count = 0; count < PortCount; count++) { if ((openSockfd[boundPortCount] = OpenTCPSocket()) == ERROR) { @@ -1066,7 +1067,7 @@ int BindPorts() if (!boundPortCount) { log(DEFAULT,"InspIRCd: startup: no ports bound, bailing!"); - printf("\nERROR: Was not able to bind any of %lu ports! Please check your configuration.\n\n", (unsigned long)portCount); + printf("\nERROR: Was not able to bind any of %lu ports! Please check your configuration.\n\n", (unsigned long)PortCount); return (ERROR); } |