summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-04-01 13:29:11 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-04-01 13:29:11 +0000
commit63188bd3fe5bdfa9221a3d4feda6294e6193a91e (patch)
treeccffe15f918be458326a8df54bed4a4933f9b81f
parent1078718b3c90e9653ffb1d92054c7740abf11356 (diff)
Fixed issue where /connect crashes the ircd if no default routes defined
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@348 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r--src/InspIRCd.layout30
-rw-r--r--src/inspircd.cpp11
2 files changed, 24 insertions, 17 deletions
diff --git a/src/InspIRCd.layout b/src/InspIRCd.layout
index 4f5a21d68..76868c48f 100644
--- a/src/InspIRCd.layout
+++ b/src/InspIRCd.layout
@@ -1,6 +1,6 @@
[Editors]
-Focused=25
-Order=1,7,3,2,0,6,5,4,-1,25
+Focused=1
+Order=1,7,3,2,0,6,5,4,25
[Editor_0]
Open=1
@@ -12,10 +12,10 @@ LeftChar=1
[Editor_1]
Open=1
-Top=0
-CursorCol=11
-CursorRow=1918
-TopLine=1871
+Top=1
+CursorCol=1
+CursorRow=3562
+TopLine=3521
LeftChar=1
[Editor_2]
@@ -31,7 +31,7 @@ Open=1
Top=0
CursorCol=1
CursorRow=1
-TopLine=19
+TopLine=6
LeftChar=1
[Editor_4]
@@ -63,7 +63,7 @@ Open=1
Top=0
CursorCol=1
CursorRow=1
-TopLine=19
+TopLine=6
LeftChar=1
[Editor_8]
@@ -99,7 +99,7 @@ TopLine=1
LeftChar=1
[Editor_12]
-Open=1
+Open=0
Top=0
CursorCol=1
CursorRow=142
@@ -139,7 +139,7 @@ TopLine=1
LeftChar=1
[Editor_17]
-Open=1
+Open=0
Top=0
CursorCol=1
CursorRow=1
@@ -163,7 +163,7 @@ TopLine=1
LeftChar=1
[Editor_20]
-Open=1
+Open=0
Top=0
CursorCol=13
CursorRow=271
@@ -179,7 +179,7 @@ TopLine=1
LeftChar=1
[Editor_22]
-Open=1
+Open=0
Top=0
CursorCol=1
CursorRow=1
@@ -203,8 +203,8 @@ TopLine=1
LeftChar=1
[Editor_25]
Open=1
-Top=1
-CursorCol=1
-CursorRow=26
+Top=0
+CursorCol=2
+CursorRow=22
TopLine=1
LeftChar=1
diff --git a/src/inspircd.cpp b/src/inspircd.cpp
index 23d32c830..996a1ee88 100644
--- a/src/inspircd.cpp
+++ b/src/inspircd.cpp
@@ -3550,9 +3550,16 @@ void handle_stats(char **parameters, int pcnt, userrec *user)
void handle_connect(char **parameters, int pcnt, userrec *user)
{
WriteServ(user->fd,"NOTICE %s :*** Connecting to %s port %s...",user->nick,parameters[0],parameters[1]);
- if (!me[defaultRoute]->BeginLink(parameters[0],atoi(parameters[1]),"password"))
+ if (me[defaultRoute])
{
- WriteServ(user->fd,"NOTICE %s :*** Failed to send auth packet to %s!",user->nick,parameters[0]);
+ if (!me[defaultRoute]->BeginLink(parameters[0],atoi(parameters[1]),"password"))
+ {
+ WriteServ(user->fd,"NOTICE %s :*** Failed to send auth packet to %s!",user->nick,parameters[0]);
+ }
+ }
+ else
+ {
+ WriteServ(user->fd,"NOTICE %s :No default route is defined for server connections on this server",user->nick);
}
}