Allow more than one _functioning_ name= in a UWorld block.
authorMichael Poole <mdpoole@troilus.org>
Sat, 23 Apr 2005 13:49:41 +0000 (13:49 +0000)
committerMichael Poole <mdpoole@troilus.org>
Sat, 23 Apr 2005 13:49:41 +0000 (13:49 +0000)
git-svn-id: file:///home/klmitch/undernet-ircu/undernet-ircu-svn/ircu2/trunk@1378 c9e4aea6-c8fd-4c43-8297-357d70d61c8c

ChangeLog
doc/example.conf
ircd/ircd_parser.y

index 8fcb69a5ddf1ce1e60f09d756cbaa1c886ac529e..0d7457b7f34cc42b7d69eb9b00ac1cfe0ec6195a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2005-04-23  Michael Poole <mdpoole@troilus.org>
+
+       * doc/example.conf (UWorld): Illustrate new config extension.
+
+       * ircd/ircd_parser.y (uworldblock): Do the expected thing when
+       multiple name= entries are present.
+
 2005-04-22  Michael Poole <mdpoole@troilus.org>
 
        * RELEASE.NOTES: Silence exceptions use ~, not -.  Oops!
index 2cda2e04fd4902be5430f357be66cc2b0abac3c1..930fe43c2946093461a95cac2f7bfa6a7e75220b 100644 (file)
@@ -396,6 +396,8 @@ motd {
 #  name = "relservername";
 # };
 #
+# You may have have more than one name listed in each block.
+#
 # Note: (1) These lines are agreed on by every server admin on Undernet;
 # (2) These lines must be the same on every single server, or results
 # will be disasterous; (3) This is a useful feature, not something that
@@ -413,29 +415,13 @@ motd {
 
 UWorld {
  name = "uworld.eu.undernet.org";
-};
-UWorld {
  name = "uworld2.undernet.org";
-};
-UWorld {
  name = "uworld.undernet.org";
-};
-UWorld {
  name = "channels.undernet.org";
-};
-UWorld {
  name = "channels2.undernet.org";
-};
-UWorld {
  name = "channels3.undernet.org";
-};
-UWorld {
  name = "channels4.undernet.org";
-};
-UWorld {
  name = "channels5.undernet.org";
-};
-UWorld {
  name = "channels6.undernet.org";
 };
 
index 1c65d657078901718ed293b2a0d315c2c23564cf..d2f37632723716f8852c22271b81fd4a974a85b2 100644 (file)
@@ -471,26 +471,14 @@ connectmaxhops: MAXHOPS '=' expr ';'
   maxlinks = $3;
 };
 
-uworldblock: UWORLD '{' uworlditems '}' ';'
-{
- if (name)
- {
-  struct ConfItem *aconf = make_conf(CONF_UWORLD);
-  aconf->host = name;
- }
- else
- {
-  MyFree(name);
-  parse_error("Bad UWorld block");
- }
- name = NULL;
-};
+uworldblock: UWORLD '{' uworlditems '}' ';';
 uworlditems: uworlditem uworlditems | uworlditem;
 uworlditem: uworldname | error;
 uworldname: NAME '=' QSTRING ';'
 {
- MyFree(name);
- DupString(name, $3);
+ struct ConfItem *aconf;
+ aconf = make_conf(CONF_UWORLD);
+ DupString(aconf->host, $3);
 };
 
 operblock: OPER '{' operitems '}' ';'