/[svn]/ircd-hybrid/trunk/src/conf_parser.c
ViewVC logotype

Diff of /ircd-hybrid/trunk/src/conf_parser.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1646 by michael, Wed Nov 7 21:02:43 2012 UTC revision 1647 by michael, Fri Nov 9 20:11:58 2012 UTC
# Line 100  Line 100 
100    
101  int yylex(void);  int yylex(void);
102    
 static char *class_name = NULL;  
 static struct MaskItem *yy_conf = NULL;  
 static struct ClassItem *yy_class = NULL;  
 static char *yy_class_name = NULL;  
   
 static dlink_list col_conf_list  = { NULL, NULL, 0 };  
 static unsigned int listener_flags = 0;  
 static unsigned int regex_ban = 0;  
 static char userbuf[IRCD_BUFSIZE];  
 static char hostbuf[IRCD_BUFSIZE];  
 static char reasonbuf[REASONLEN + 1];  
 static char gecos_name[REALLEN * 4];  
 static char lfile[IRCD_BUFSIZE];  
 static unsigned int ltype = 0;  
 static unsigned int lsize = 0;  
 static char *resv_reason = NULL;  
 static char *listener_address = NULL;  
   
103  static struct  static struct
104  {  {
105    struct {    struct {
# Line 132  static struct Line 114  static struct
114      user,      user,
115      host,      host,
116      addr,      addr,
117      pass,      bind,
118      file,      file,
119        ciph,
120        rpass,
121        spass,
122      class;      class;
123    
124    struct {    struct {
125      unsigned int value;      unsigned int value;
126    } flags,    } flags,
127      modes,      modes,
128        size,
129        type,
130      port,      port,
131        aftype,
132      ping_freq,      ping_freq,
133      max_perip,      max_perip,
134      con_freq,      con_freq,
# Line 186  reset_block_state(void) Line 174  reset_block_state(void)
174    
175    
176  /* Line 358 of yacc.c  */  /* Line 358 of yacc.c  */
177  #line 190 "conf_parser.c"  #line 178 "conf_parser.c"
178    
179  # ifndef YY_NULL  # ifndef YY_NULL
180  #  if defined __cplusplus && 201103L <= __cplusplus  #  if defined __cplusplus && 201103L <= __cplusplus
# Line 654  extern int yydebug; Line 642  extern int yydebug;
642  typedef union YYSTYPE  typedef union YYSTYPE
643  {  {
644  /* Line 374 of yacc.c  */  /* Line 374 of yacc.c  */
645  #line 147 "conf_parser.y"  #line 135 "conf_parser.y"
646    
647    int number;    int number;
648    char *string;    char *string;
649    
650    
651  /* Line 374 of yacc.c  */  /* Line 374 of yacc.c  */
652  #line 665 "conf_parser.c"  #line 653 "conf_parser.c"
653  } YYSTYPE;  } YYSTYPE;
654  # define YYSTYPE_IS_TRIVIAL 1  # define YYSTYPE_IS_TRIVIAL 1
655  # define yystype YYSTYPE /* obsolescent; will be withdrawn */  # define yystype YYSTYPE /* obsolescent; will be withdrawn */
# Line 689  int yyparse (); Line 677  int yyparse ();
677  /* Copy the second part of user declarations.  */  /* Copy the second part of user declarations.  */
678    
679  /* Line 377 of yacc.c  */  /* Line 377 of yacc.c  */
680  #line 693 "conf_parser.c"  #line 681 "conf_parser.c"
681    
682  #ifdef short  #ifdef short
683  # undef short  # undef short
# Line 1248  static const yytype_int16 yyrhs[] = Line 1236  static const yytype_int16 yyrhs[] =
1236  /* YYRLINE[YYN] -- source line where rule number YYN was defined.  */  /* YYRLINE[YYN] -- source line where rule number YYN was defined.  */
1237  static const yytype_uint16 yyrline[] =  static const yytype_uint16 yyrline[] =
1238  {  {
1239         0,   366,   366,   367,   370,   371,   372,   373,   374,   375,         0,   354,   354,   355,   358,   359,   360,   361,   362,   363,
1240       376,   377,   378,   379,   380,   381,   382,   383,   384,   385,       364,   365,   366,   367,   368,   369,   370,   371,   372,   373,
1241       386,   387,   388,   389,   390,   391,   395,   395,   396,   400,       374,   375,   376,   377,   378,   379,   383,   383,   384,   388,
1242       404,   408,   412,   416,   422,   422,   423,   424,   425,   426,       392,   396,   400,   404,   410,   410,   411,   412,   413,   414,
1243       433,   436,   436,   437,   437,   437,   439,   445,   452,   454,       421,   424,   424,   425,   425,   425,   427,   433,   440,   442,
1244       454,   455,   455,   456,   456,   457,   457,   458,   458,   459,       442,   443,   443,   444,   444,   445,   445,   446,   446,   447,
1245       459,   460,   460,   461,   461,   462,   463,   466,   467,   469,       447,   448,   448,   449,   449,   450,   451,   454,   455,   457,
1246       469,   470,   476,   484,   484,   485,   491,   499,   538,   597,       457,   458,   464,   472,   472,   473,   479,   487,   526,   585,
1247       625,   633,   648,   663,   672,   686,   695,   723,   753,   776,       613,   621,   636,   651,   660,   674,   683,   711,   741,   764,
1248       785,   787,   787,   788,   788,   789,   789,   791,   800,   809,       773,   775,   775,   776,   776,   777,   777,   779,   788,   797,
1249       821,   822,   822,   824,   824,   825,   827,   834,   834,   844,       809,   810,   810,   812,   812,   813,   815,   822,   822,   835,
1250       845,   847,   847,   848,   848,   850,   855,   858,   864,   863,       836,   838,   838,   839,   839,   841,   849,   852,   858,   857,
1251       869,   869,   870,   874,   878,   882,   886,   890,   894,   905,       863,   863,   864,   868,   872,   876,   880,   884,   888,   899,
1252       904,   983,   983,   984,   984,   984,   985,   985,   985,   986,       898,   977,   977,   978,   978,   978,   979,   979,   979,   980,
1253       986,   986,   988,   994,  1000,  1006,  1017,  1023,  1030,  1029,       980,   980,   982,   988,   994,  1000,  1011,  1017,  1024,  1023,
1254      1035,  1035,  1036,  1040,  1044,  1048,  1052,  1056,  1060,  1064,      1029,  1029,  1030,  1034,  1038,  1042,  1046,  1050,  1054,  1058,
1255      1068,  1072,  1076,  1080,  1084,  1088,  1092,  1096,  1100,  1104,      1062,  1066,  1070,  1074,  1078,  1082,  1086,  1090,  1094,  1098,
1256      1108,  1112,  1119,  1118,  1124,  1124,  1125,  1129,  1133,  1137,      1102,  1106,  1113,  1112,  1118,  1118,  1119,  1123,  1127,  1131,
1257      1141,  1145,  1149,  1153,  1157,  1161,  1165,  1169,  1173,  1177,      1135,  1139,  1143,  1147,  1151,  1155,  1159,  1163,  1167,  1171,
1258      1181,  1185,  1189,  1193,  1197,  1208,  1207,  1253,  1253,  1254,      1175,  1179,  1183,  1187,  1191,  1202,  1201,  1243,  1243,  1244,
1259      1255,  1255,  1256,  1257,  1258,  1259,  1260,  1261,  1262,  1263,      1245,  1245,  1246,  1247,  1248,  1249,  1250,  1251,  1252,  1253,
1260      1264,  1264,  1265,  1267,  1276,  1282,  1288,  1294,  1300,  1306,      1254,  1254,  1255,  1257,  1263,  1269,  1275,  1281,  1287,  1293,
1261      1312,  1318,  1324,  1331,  1337,  1343,  1353,  1352,  1359,  1358,      1299,  1305,  1311,  1318,  1324,  1330,  1340,  1339,  1346,  1345,
1262      1363,  1363,  1364,  1368,  1372,  1378,  1378,  1379,  1379,  1379,      1350,  1350,  1351,  1355,  1359,  1365,  1365,  1366,  1366,  1366,
1263      1379,  1379,  1381,  1381,  1383,  1383,  1385,  1399,  1419,  1425,      1366,  1366,  1368,  1368,  1370,  1370,  1372,  1386,  1406,  1412,
1264      1435,  1434,  1476,  1476,  1477,  1477,  1477,  1477,  1478,  1478,      1422,  1421,  1463,  1463,  1464,  1464,  1464,  1464,  1465,  1465,
1265      1478,  1479,  1479,  1481,  1487,  1493,  1499,  1511,  1510,  1516,      1465,  1466,  1466,  1468,  1474,  1480,  1486,  1498,  1497,  1503,
1266      1516,  1517,  1521,  1525,  1529,  1533,  1537,  1541,  1545,  1549,      1503,  1504,  1508,  1512,  1516,  1520,  1524,  1528,  1532,  1536,
1267      1555,  1569,  1578,  1591,  1590,  1606,  1606,  1607,  1607,  1607,      1542,  1556,  1565,  1579,  1578,  1587,  1587,  1588,  1588,  1588,
1268      1607,  1609,  1618,  1633,  1646,  1648,  1648,  1649,  1649,  1651,      1588,  1590,  1596,  1605,  1614,  1616,  1616,  1617,  1617,  1619,
1269      1667,  1666,  1681,  1681,  1682,  1682,  1682,  1682,  1684,  1693,      1635,  1634,  1659,  1659,  1660,  1660,  1660,  1660,  1662,  1668,
1270      1716,  1715,  1721,  1721,  1722,  1726,  1730,  1734,  1738,  1742,      1688,  1687,  1693,  1693,  1694,  1698,  1702,  1706,  1710,  1714,
1271      1746,  1750,  1754,  1758,  1768,  1767,  1783,  1783,  1784,  1784,      1718,  1722,  1726,  1730,  1740,  1739,  1760,  1760,  1761,  1761,
1272      1784,  1786,  1793,  1792,  1798,  1798,  1799,  1803,  1807,  1811,      1761,  1763,  1770,  1769,  1775,  1775,  1776,  1780,  1784,  1788,
1273      1815,  1819,  1823,  1827,  1831,  1835,  1845,  1844,  1893,  1893,      1792,  1796,  1800,  1804,  1808,  1812,  1822,  1821,  1887,  1887,
1274      1894,  1894,  1894,  1895,  1895,  1896,  1896,  1896,  1897,  1897,      1888,  1888,  1888,  1889,  1889,  1890,  1890,  1890,  1891,  1891,
1275      1897,  1898,  1898,  1899,  1901,  1910,  1919,  1945,  1963,  1981,      1891,  1892,  1892,  1893,  1895,  1901,  1907,  1913,  1926,  1939,
1276      1987,  1991,  2000,  1999,  2003,  2003,  2004,  2008,  2014,  2025,      1945,  1949,  1958,  1957,  1962,  1962,  1963,  1967,  1973,  1984,
1277      2035,  2046,  2055,  2074,  2073,  2137,  2136,  2140,  2140,  2141,      1990,  1996,  2002,  2018,  2017,  2080,  2079,  2085,  2085,  2086,
1278      2147,  2147,  2148,  2148,  2148,  2148,  2150,  2169,  2179,  2178,      2092,  2092,  2093,  2093,  2093,  2093,  2095,  2115,  2125,  2124,
1279      2205,  2205,  2206,  2206,  2206,  2208,  2214,  2223,  2225,  2225,      2151,  2151,  2152,  2152,  2152,  2154,  2160,  2169,  2171,  2171,
1280      2226,  2226,  2228,  2246,  2245,  2291,  2290,  2296,  2296,  2297,      2172,  2172,  2174,  2192,  2191,  2237,  2236,  2242,  2242,  2243,
1281      2303,  2303,  2304,  2304,  2304,  2304,  2306,  2312,  2321,  2324,      2249,  2249,  2250,  2250,  2250,  2250,  2252,  2258,  2267,  2270,
1282      2324,  2325,  2325,  2326,  2326,  2327,  2327,  2328,  2328,  2329,      2270,  2271,  2271,  2272,  2272,  2273,  2273,  2274,  2274,  2275,
1283      2329,  2330,  2331,  2332,  2332,  2333,  2333,  2334,  2334,  2335,      2275,  2276,  2277,  2278,  2278,  2279,  2279,  2280,  2280,  2281,
1284      2335,  2336,  2336,  2337,  2337,  2338,  2339,  2339,  2340,  2340,      2281,  2282,  2282,  2283,  2283,  2284,  2285,  2285,  2286,  2286,
1285      2341,  2341,  2342,  2342,  2343,  2343,  2344,  2345,  2345,  2346,      2287,  2287,  2288,  2288,  2289,  2289,  2290,  2291,  2291,  2292,
1286      2347,  2348,  2348,  2349,  2349,  2350,  2351,  2352,  2353,  2353,      2293,  2294,  2294,  2295,  2295,  2296,  2297,  2298,  2299,  2299,
1287      2354,  2357,  2362,  2368,  2374,  2380,  2385,  2390,  2395,  2400,      2300,  2303,  2308,  2314,  2320,  2326,  2331,  2336,  2341,  2346,
1288      2405,  2410,  2415,  2420,  2425,  2430,  2435,  2440,  2445,  2450,      2351,  2356,  2361,  2366,  2371,  2376,  2381,  2386,  2391,  2396,
1289      2456,  2467,  2472,  2477,  2482,  2487,  2492,  2495,  2500,  2503,      2402,  2413,  2418,  2423,  2428,  2433,  2438,  2441,  2446,  2449,
1290      2508,  2513,  2518,  2523,  2528,  2533,  2538,  2543,  2548,  2559,      2454,  2459,  2464,  2469,  2474,  2479,  2484,  2489,  2494,  2505,
1291      2564,  2569,  2574,  2583,  2592,  2597,  2602,  2608,  2607,  2612,      2510,  2515,  2520,  2529,  2538,  2543,  2548,  2554,  2553,  2558,
1292      2612,  2613,  2616,  2619,  2622,  2625,  2628,  2631,  2634,  2637,      2558,  2559,  2562,  2565,  2568,  2571,  2574,  2577,  2580,  2583,
1293      2640,  2643,  2646,  2649,  2652,  2655,  2658,  2661,  2664,  2667,      2586,  2589,  2592,  2595,  2598,  2601,  2604,  2607,  2610,  2613,
1294      2670,  2676,  2675,  2680,  2680,  2681,  2684,  2687,  2690,  2693,      2616,  2622,  2621,  2626,  2626,  2627,  2630,  2633,  2636,  2639,
1295      2696,  2699,  2702,  2705,  2708,  2711,  2714,  2717,  2720,  2723,      2642,  2645,  2648,  2651,  2654,  2657,  2660,  2663,  2666,  2669,
1296      2726,  2729,  2732,  2735,  2738,  2743,  2748,  2753,  2762,  2765,      2672,  2675,  2678,  2681,  2684,  2689,  2694,  2699,  2708,  2711,
1297      2765,  2766,  2767,  2767,  2768,  2768,  2769,  2769,  2770,  2771,      2711,  2712,  2713,  2713,  2714,  2714,  2715,  2715,  2716,  2717,
1298      2771,  2772,  2773,  2773,  2774,  2774,  2776,  2781,  2786,  2791,      2717,  2718,  2719,  2719,  2720,  2720,  2722,  2727,  2732,  2737,
1299      2796,  2801,  2806,  2811,  2816,  2821,  2826,  2831,  2836,  2841,      2742,  2747,  2752,  2757,  2762,  2767,  2772,  2777,  2782,  2787,
1300      2849,  2852,  2852,  2853,  2853,  2854,  2855,  2855,  2856,  2857,      2795,  2798,  2798,  2799,  2799,  2800,  2801,  2801,  2802,  2803,
1301      2859,  2865,  2871,  2880,  2894,  2900      2805,  2811,  2817,  2826,  2840,  2846
1302  };  };
1303  #endif  #endif
1304    
# Line 3170  yyreduce: Line 3158  yyreduce:
3158      {      {
3159          case 26:          case 26:
3160  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3161  #line 395 "conf_parser.y"  #line 383 "conf_parser.y"
3162      { (yyval.number) = 0; }      { (yyval.number) = 0; }
3163      break;      break;
3164    
3165    case 28:    case 28:
3166  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3167  #line 397 "conf_parser.y"  #line 385 "conf_parser.y"
3168      {      {
3169                          (yyval.number) = (yyvsp[(1) - (2)].number) + (yyvsp[(2) - (2)].number);                          (yyval.number) = (yyvsp[(1) - (2)].number) + (yyvsp[(2) - (2)].number);
3170                  }                  }
# Line 3184  yyreduce: Line 3172  yyreduce:
3172    
3173    case 29:    case 29:
3174  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3175  #line 401 "conf_parser.y"  #line 389 "conf_parser.y"
3176      {      {
3177                          (yyval.number) = (yyvsp[(1) - (3)].number) + (yyvsp[(3) - (3)].number);                          (yyval.number) = (yyvsp[(1) - (3)].number) + (yyvsp[(3) - (3)].number);
3178                  }                  }
# Line 3192  yyreduce: Line 3180  yyreduce:
3180    
3181    case 30:    case 30:
3182  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3183  #line 405 "conf_parser.y"  #line 393 "conf_parser.y"
3184      {      {
3185                          (yyval.number) = (yyvsp[(1) - (3)].number) * 60 + (yyvsp[(3) - (3)].number);                          (yyval.number) = (yyvsp[(1) - (3)].number) * 60 + (yyvsp[(3) - (3)].number);
3186                  }                  }
# Line 3200  yyreduce: Line 3188  yyreduce:
3188    
3189    case 31:    case 31:
3190  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3191  #line 409 "conf_parser.y"  #line 397 "conf_parser.y"
3192      {      {
3193                          (yyval.number) = (yyvsp[(1) - (3)].number) * 60 * 60 + (yyvsp[(3) - (3)].number);                          (yyval.number) = (yyvsp[(1) - (3)].number) * 60 * 60 + (yyvsp[(3) - (3)].number);
3194                  }                  }
# Line 3208  yyreduce: Line 3196  yyreduce:
3196    
3197    case 32:    case 32:
3198  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3199  #line 413 "conf_parser.y"  #line 401 "conf_parser.y"
3200      {      {
3201                          (yyval.number) = (yyvsp[(1) - (3)].number) * 60 * 60 * 24 + (yyvsp[(3) - (3)].number);                          (yyval.number) = (yyvsp[(1) - (3)].number) * 60 * 60 * 24 + (yyvsp[(3) - (3)].number);
3202                  }                  }
# Line 3216  yyreduce: Line 3204  yyreduce:
3204    
3205    case 33:    case 33:
3206  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3207  #line 417 "conf_parser.y"  #line 405 "conf_parser.y"
3208      {      {
3209                          (yyval.number) = (yyvsp[(1) - (3)].number) * 60 * 60 * 24 * 7 + (yyvsp[(3) - (3)].number);                          (yyval.number) = (yyvsp[(1) - (3)].number) * 60 * 60 * 24 * 7 + (yyvsp[(3) - (3)].number);
3210                  }                  }
# Line 3224  yyreduce: Line 3212  yyreduce:
3212    
3213    case 34:    case 34:
3214  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3215  #line 422 "conf_parser.y"  #line 410 "conf_parser.y"
3216      { (yyval.number) = 0; }      { (yyval.number) = 0; }
3217      break;      break;
3218    
3219    case 36:    case 36:
3220  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3221  #line 423 "conf_parser.y"  #line 411 "conf_parser.y"
3222      { (yyval.number) = (yyvsp[(1) - (2)].number) + (yyvsp[(2) - (2)].number); }      { (yyval.number) = (yyvsp[(1) - (2)].number) + (yyvsp[(2) - (2)].number); }
3223      break;      break;
3224    
3225    case 37:    case 37:
3226  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3227  #line 424 "conf_parser.y"  #line 412 "conf_parser.y"
3228      { (yyval.number) = (yyvsp[(1) - (3)].number) + (yyvsp[(3) - (3)].number); }      { (yyval.number) = (yyvsp[(1) - (3)].number) + (yyvsp[(3) - (3)].number); }
3229      break;      break;
3230    
3231    case 38:    case 38:
3232  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3233  #line 425 "conf_parser.y"  #line 413 "conf_parser.y"
3234      { (yyval.number) = (yyvsp[(1) - (3)].number) * 1024 + (yyvsp[(3) - (3)].number); }      { (yyval.number) = (yyvsp[(1) - (3)].number) * 1024 + (yyvsp[(3) - (3)].number); }
3235      break;      break;
3236    
3237    case 39:    case 39:
3238  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3239  #line 426 "conf_parser.y"  #line 414 "conf_parser.y"
3240      { (yyval.number) = (yyvsp[(1) - (3)].number) * 1024 * 1024 + (yyvsp[(3) - (3)].number); }      { (yyval.number) = (yyvsp[(1) - (3)].number) * 1024 * 1024 + (yyvsp[(3) - (3)].number); }
3241      break;      break;
3242    
3243    case 46:    case 46:
3244  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3245  #line 440 "conf_parser.y"  #line 428 "conf_parser.y"
3246      {      {
3247    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3248      add_conf_module(libio_basename(yylval.string));      add_conf_module(libio_basename(yylval.string));
# Line 3263  yyreduce: Line 3251  yyreduce:
3251    
3252    case 47:    case 47:
3253  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3254  #line 446 "conf_parser.y"  #line 434 "conf_parser.y"
3255      {      {
3256    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3257      mod_add_path(yylval.string);      mod_add_path(yylval.string);
# Line 3272  yyreduce: Line 3260  yyreduce:
3260    
3261    case 71:    case 71:
3262  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3263  #line 471 "conf_parser.y"  #line 459 "conf_parser.y"
3264      {      {
3265  #ifdef HAVE_LIBCRYPTO  #ifdef HAVE_LIBCRYPTO
3266    if (conf_parser_ctx.pass == 2 && ServerInfo.client_ctx)    if (conf_parser_ctx.pass == 2 && ServerInfo.client_ctx)
# Line 3283  yyreduce: Line 3271  yyreduce:
3271    
3272    case 72:    case 72:
3273  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3274  #line 477 "conf_parser.y"  #line 465 "conf_parser.y"
3275      {      {
3276  #ifdef HAVE_LIBCRYPTO  #ifdef HAVE_LIBCRYPTO
3277    if (conf_parser_ctx.pass == 2 && ServerInfo.client_ctx)    if (conf_parser_ctx.pass == 2 && ServerInfo.client_ctx)
# Line 3294  yyreduce: Line 3282  yyreduce:
3282    
3283    case 75:    case 75:
3284  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3285  #line 486 "conf_parser.y"  #line 474 "conf_parser.y"
3286      {      {
3287  #ifdef HAVE_LIBCRYPTO  #ifdef HAVE_LIBCRYPTO
3288    if (conf_parser_ctx.pass == 2 && ServerInfo.server_ctx)    if (conf_parser_ctx.pass == 2 && ServerInfo.server_ctx)
# Line 3305  yyreduce: Line 3293  yyreduce:
3293    
3294    case 76:    case 76:
3295  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3296  #line 492 "conf_parser.y"  #line 480 "conf_parser.y"
3297      {      {
3298  #ifdef HAVE_LIBCRYPTO  #ifdef HAVE_LIBCRYPTO
3299    if (conf_parser_ctx.pass == 2 && ServerInfo.server_ctx)    if (conf_parser_ctx.pass == 2 && ServerInfo.server_ctx)
# Line 3316  yyreduce: Line 3304  yyreduce:
3304    
3305    case 77:    case 77:
3306  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3307  #line 500 "conf_parser.y"  #line 488 "conf_parser.y"
3308      {      {
3309  #ifdef HAVE_LIBCRYPTO  #ifdef HAVE_LIBCRYPTO
3310    if (conf_parser_ctx.pass == 2 && ServerInfo.server_ctx)    if (conf_parser_ctx.pass == 2 && ServerInfo.server_ctx)
# Line 3358  yyreduce: Line 3346  yyreduce:
3346    
3347    case 78:    case 78:
3348  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3349  #line 539 "conf_parser.y"  #line 527 "conf_parser.y"
3350      {      {
3351  #ifdef HAVE_LIBCRYPTO  #ifdef HAVE_LIBCRYPTO
3352    if (conf_parser_ctx.pass == 1)    if (conf_parser_ctx.pass == 1)
# Line 3420  yyreduce: Line 3408  yyreduce:
3408    
3409    case 79:    case 79:
3410  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3411  #line 598 "conf_parser.y"  #line 586 "conf_parser.y"
3412      {      {
3413  /* TBD - XXX: error reporting */  /* TBD - XXX: error reporting */
3414  #ifdef HAVE_LIBCRYPTO  #ifdef HAVE_LIBCRYPTO
# Line 3451  yyreduce: Line 3439  yyreduce:
3439    
3440    case 80:    case 80:
3441  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3442  #line 626 "conf_parser.y"  #line 614 "conf_parser.y"
3443      {      {
3444  #ifdef HAVE_LIBCRYPTO  #ifdef HAVE_LIBCRYPTO
3445    if (conf_parser_ctx.pass == 2 && ServerInfo.server_ctx)    if (conf_parser_ctx.pass == 2 && ServerInfo.server_ctx)
# Line 3462  yyreduce: Line 3450  yyreduce:
3450    
3451    case 81:    case 81:
3452  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3453  #line 634 "conf_parser.y"  #line 622 "conf_parser.y"
3454      {      {
3455    /* this isn't rehashable */    /* this isn't rehashable */
3456    if (conf_parser_ctx.pass == 2 && !ServerInfo.name)    if (conf_parser_ctx.pass == 2 && !ServerInfo.name)
# Line 3480  yyreduce: Line 3468  yyreduce:
3468    
3469    case 82:    case 82:
3470  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3471  #line 649 "conf_parser.y"  #line 637 "conf_parser.y"
3472      {      {
3473    /* this isn't rehashable */    /* this isn't rehashable */
3474    if (conf_parser_ctx.pass == 2 && !ServerInfo.sid)    if (conf_parser_ctx.pass == 2 && !ServerInfo.sid)
# Line 3498  yyreduce: Line 3486  yyreduce:
3486    
3487    case 83:    case 83:
3488  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3489  #line 664 "conf_parser.y"  #line 652 "conf_parser.y"
3490      {      {
3491    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3492    {    {
# Line 3510  yyreduce: Line 3498  yyreduce:
3498    
3499    case 84:    case 84:
3500  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3501  #line 673 "conf_parser.y"  #line 661 "conf_parser.y"
3502      {      {
3503    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3504    {    {
# Line 3527  yyreduce: Line 3515  yyreduce:
3515    
3516    case 85:    case 85:
3517  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3518  #line 687 "conf_parser.y"  #line 675 "conf_parser.y"
3519      {      {
3520    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3521    {    {
# Line 3539  yyreduce: Line 3527  yyreduce:
3527    
3528    case 86:    case 86:
3529  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3530  #line 696 "conf_parser.y"  #line 684 "conf_parser.y"
3531      {      {
3532    if (conf_parser_ctx.pass == 2 && *yylval.string != '*')    if (conf_parser_ctx.pass == 2 && *yylval.string != '*')
3533    {    {
# Line 3570  yyreduce: Line 3558  yyreduce:
3558    
3559    case 87:    case 87:
3560  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3561  #line 724 "conf_parser.y"  #line 712 "conf_parser.y"
3562      {      {
3563  #ifdef IPV6  #ifdef IPV6
3564    if (conf_parser_ctx.pass == 2 && *yylval.string != '*')    if (conf_parser_ctx.pass == 2 && *yylval.string != '*')
# Line 3603  yyreduce: Line 3591  yyreduce:
3591    
3592    case 88:    case 88:
3593  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3594  #line 754 "conf_parser.y"  #line 742 "conf_parser.y"
3595      {      {
3596    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3597    {    {
# Line 3629  yyreduce: Line 3617  yyreduce:
3617    
3618    case 89:    case 89:
3619  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3620  #line 777 "conf_parser.y"  #line 765 "conf_parser.y"
3621      {      {
3622    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3623      ServerInfo.hub = yylval.number;      ServerInfo.hub = yylval.number;
# Line 3638  yyreduce: Line 3626  yyreduce:
3626    
3627    case 97:    case 97:
3628  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3629  #line 792 "conf_parser.y"  #line 780 "conf_parser.y"
3630      {      {
3631    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3632    {    {
# Line 3650  yyreduce: Line 3638  yyreduce:
3638    
3639    case 98:    case 98:
3640  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3641  #line 801 "conf_parser.y"  #line 789 "conf_parser.y"
3642      {      {
3643    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3644    {    {
# Line 3662  yyreduce: Line 3650  yyreduce:
3650    
3651    case 99:    case 99:
3652  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3653  #line 810 "conf_parser.y"  #line 798 "conf_parser.y"
3654      {      {
3655    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3656    {    {
# Line 3674  yyreduce: Line 3662  yyreduce:
3662    
3663    case 106:    case 106:
3664  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3665  #line 828 "conf_parser.y"  #line 816 "conf_parser.y"
3666      {      {
3667    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3668      ConfigLoggingEntry.use_logging = yylval.number;      ConfigLoggingEntry.use_logging = yylval.number;
# Line 3683  yyreduce: Line 3671  yyreduce:
3671    
3672    case 107:    case 107:
3673  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3674  #line 834 "conf_parser.y"  #line 822 "conf_parser.y"
3675      {      {
3676    lfile[0] = '\0';    if (conf_parser_ctx.pass == 2)
3677    ltype = 0;      reset_block_state();
   lsize = 0;  
3678  }  }
3679      break;      break;
3680    
3681    case 108:    case 108:
3682  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3683  #line 839 "conf_parser.y"  #line 826 "conf_parser.y"
3684      {      {
3685    if (conf_parser_ctx.pass == 2 && ltype > 0)    if (conf_parser_ctx.pass != 2)
3686      log_add_file(ltype, lsize, lfile);      break;
3687    
3688      if (block_state.type.value && block_state.file.buf[0])
3689        log_add_file(block_state.type.value, block_state.size.value,
3690                     block_state.file.buf);
3691  }  }
3692      break;      break;
3693    
3694    case 115:    case 115:
3695  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3696  #line 851 "conf_parser.y"  #line 842 "conf_parser.y"
3697      {      {
3698    strlcpy(lfile, yylval.string, sizeof(lfile));    if (conf_parser_ctx.pass != 2)
3699        break;
3700    
3701      strlcpy(block_state.file.buf, yylval.string, sizeof(block_state.file.buf));
3702  }  }
3703      break;      break;
3704    
3705    case 116:    case 116:
3706  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3707  #line 856 "conf_parser.y"  #line 850 "conf_parser.y"
3708      {      {
3709    lsize = (yyvsp[(3) - (4)].number);    block_state.size.value = (yyvsp[(3) - (4)].number);
3710  }  }
3711      break;      break;
3712    
3713    case 117:    case 117:
3714  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3715  #line 859 "conf_parser.y"  #line 853 "conf_parser.y"
3716      {      {
3717    lsize = 0;    block_state.size.value = 0;
3718  }  }
3719      break;      break;
3720    
3721    case 118:    case 118:
3722  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3723  #line 864 "conf_parser.y"  #line 858 "conf_parser.y"
3724      {      {
3725    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3726      ltype = 0;      block_state.type.value = 0;
3727  }  }
3728      break;      break;
3729    
3730    case 122:    case 122:
3731  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3732  #line 871 "conf_parser.y"  #line 865 "conf_parser.y"
3733      {      {
3734    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3735      ltype = LOG_TYPE_USER;      block_state.type.value = LOG_TYPE_USER;
3736  }  }
3737      break;      break;
3738    
3739    case 123:    case 123:
3740  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3741  #line 875 "conf_parser.y"  #line 869 "conf_parser.y"
3742      {      {
3743    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3744      ltype = LOG_TYPE_OPER;      block_state.type.value = LOG_TYPE_OPER;
3745  }  }
3746      break;      break;
3747    
3748    case 124:    case 124:
3749  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3750  #line 879 "conf_parser.y"  #line 873 "conf_parser.y"
3751      {      {
3752    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3753      ltype = LOG_TYPE_GLINE;      block_state.type.value = LOG_TYPE_GLINE;
3754  }  }
3755      break;      break;
3756    
3757    case 125:    case 125:
3758  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3759  #line 883 "conf_parser.y"  #line 877 "conf_parser.y"
3760      {      {
3761    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3762      ltype = LOG_TYPE_DLINE;      block_state.type.value = LOG_TYPE_DLINE;
3763  }  }
3764      break;      break;
3765    
3766    case 126:    case 126:
3767  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3768  #line 887 "conf_parser.y"  #line 881 "conf_parser.y"
3769      {      {
3770    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3771      ltype = LOG_TYPE_KLINE;      block_state.type.value = LOG_TYPE_KLINE;
3772  }  }
3773      break;      break;
3774    
3775    case 127:    case 127:
3776  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3777  #line 891 "conf_parser.y"  #line 885 "conf_parser.y"
3778      {      {
3779    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3780      ltype = LOG_TYPE_KILL;      block_state.type.value = LOG_TYPE_KILL;
3781  }  }
3782      break;      break;
3783    
3784    case 128:    case 128:
3785  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3786  #line 895 "conf_parser.y"  #line 889 "conf_parser.y"
3787      {      {
3788    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3789      ltype = LOG_TYPE_DEBUG;      block_state.type.value = LOG_TYPE_DEBUG;
3790  }  }
3791      break;      break;
3792    
3793    case 129:    case 129:
3794  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3795  #line 905 "conf_parser.y"  #line 899 "conf_parser.y"
3796      {      {
3797    if (conf_parser_ctx.pass != 2)    if (conf_parser_ctx.pass != 2)
3798      break;      break;
# Line 3810  yyreduce: Line 3804  yyreduce:
3804    
3805    case 130:    case 130:
3806  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3807  #line 912 "conf_parser.y"  #line 906 "conf_parser.y"
3808      {      {
3809    dlink_node *ptr = NULL;    dlink_node *ptr = NULL;
3810    
# Line 3821  yyreduce: Line 3815  yyreduce:
3815      break;      break;
3816  #ifdef HAVE_LIBCRYPTO  #ifdef HAVE_LIBCRYPTO
3817    if (!(block_state.file.buf[0] ||    if (!(block_state.file.buf[0] ||
3818          block_state.pass.buf[0]))          block_state.rpass.buf[0]))
3819      break;      break;
3820  #else  #else
3821    if (!block_state.pass.buf[0])    if (!block_state.rpass.buf[0])
3822      break;      break;
3823  #endif  #endif
3824    
# Line 3835  yyreduce: Line 3829  yyreduce:
3829    
3830      nuh.nuhmask  = ptr->data;      nuh.nuhmask  = ptr->data;
3831      nuh.nickptr  = NULL;      nuh.nickptr  = NULL;
3832      nuh.userptr  = userbuf;      nuh.userptr  = block_state.user.buf;
3833      nuh.hostptr  = hostbuf;      nuh.hostptr  = block_state.host.buf;
3834      nuh.nicksize = 0;      nuh.nicksize = 0;
3835      nuh.usersize = sizeof(userbuf);      nuh.usersize = sizeof(block_state.user.buf);
3836      nuh.hostsize = sizeof(hostbuf);      nuh.hostsize = sizeof(block_state.host.buf);
3837      split_nuh(&nuh);      split_nuh(&nuh);
3838    
3839      conf        = conf_make(CONF_OPER);      conf        = conf_make(CONF_OPER);
3840      conf->user  = xstrdup(userbuf);      conf->user  = xstrdup(block_state.user.buf);
3841      conf->host  = xstrdup(hostbuf);      conf->host  = xstrdup(block_state.host.buf);
3842    
3843      if (block_state.pass.buf[0])      if (block_state.rpass.buf[0])
3844        conf->passwd = xstrdup(block_state.pass.buf);        conf->passwd = xstrdup(block_state.rpass.buf);
3845    
3846      conf->flags = block_state.flags.value;      conf->flags = block_state.flags.value;
3847      conf->modes = block_state.modes.value;      conf->modes = block_state.modes.value;
# Line 3885  yyreduce: Line 3879  yyreduce:
3879    
3880    case 142:    case 142:
3881  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3882  #line 989 "conf_parser.y"  #line 983 "conf_parser.y"
3883      {      {
3884    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3885      strlcpy(block_state.name.buf, yylval.string, sizeof(block_state.name.buf));      strlcpy(block_state.name.buf, yylval.string, sizeof(block_state.name.buf));
# Line 3894  yyreduce: Line 3888  yyreduce:
3888    
3889    case 143:    case 143:
3890  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3891  #line 995 "conf_parser.y"  #line 989 "conf_parser.y"
3892      {      {
3893    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3894      dlinkAdd(xstrdup(yylval.string), make_dlink_node(), &block_state.mask.list);      dlinkAdd(xstrdup(yylval.string), make_dlink_node(), &block_state.mask.list);
# Line 3903  yyreduce: Line 3897  yyreduce:
3897    
3898    case 144:    case 144:
3899  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3900  #line 1001 "conf_parser.y"  #line 995 "conf_parser.y"
3901      {      {
3902    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3903      strlcpy(block_state.pass.buf, yylval.string, sizeof(block_state.pass.buf));      strlcpy(block_state.rpass.buf, yylval.string, sizeof(block_state.rpass.buf));
3904  }  }
3905      break;      break;
3906    
3907    case 145:    case 145:
3908  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3909  #line 1007 "conf_parser.y"  #line 1001 "conf_parser.y"
3910      {      {
3911    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3912    {    {
# Line 3926  yyreduce: Line 3920  yyreduce:
3920    
3921    case 146:    case 146:
3922  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3923  #line 1018 "conf_parser.y"  #line 1012 "conf_parser.y"
3924      {      {
3925    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3926      strlcpy(block_state.file.buf, yylval.string, sizeof(block_state.file.buf));      strlcpy(block_state.file.buf, yylval.string, sizeof(block_state.file.buf));
# Line 3935  yyreduce: Line 3929  yyreduce:
3929    
3930    case 147:    case 147:
3931  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3932  #line 1024 "conf_parser.y"  #line 1018 "conf_parser.y"
3933      {      {
3934    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3935      strlcpy(block_state.class.buf, yylval.string, sizeof(block_state.class.buf));      strlcpy(block_state.class.buf, yylval.string, sizeof(block_state.class.buf));
# Line 3944  yyreduce: Line 3938  yyreduce:
3938    
3939    case 148:    case 148:
3940  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3941  #line 1030 "conf_parser.y"  #line 1024 "conf_parser.y"
3942      {      {
3943    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3944      block_state.modes.value = 0;      block_state.modes.value = 0;
# Line 3953  yyreduce: Line 3947  yyreduce:
3947    
3948    case 152:    case 152:
3949  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3950  #line 1037 "conf_parser.y"  #line 1031 "conf_parser.y"
3951      {      {
3952    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3953      block_state.modes.value |= UMODE_BOTS;      block_state.modes.value |= UMODE_BOTS;
# Line 3962  yyreduce: Line 3956  yyreduce:
3956    
3957    case 153:    case 153:
3958  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3959  #line 1041 "conf_parser.y"  #line 1035 "conf_parser.y"
3960      {      {
3961    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3962      block_state.modes.value |= UMODE_CCONN;      block_state.modes.value |= UMODE_CCONN;
# Line 3971  yyreduce: Line 3965  yyreduce:
3965    
3966    case 154:    case 154:
3967  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3968  #line 1045 "conf_parser.y"  #line 1039 "conf_parser.y"
3969      {      {
3970    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3971      block_state.modes.value |= UMODE_CCONN_FULL;      block_state.modes.value |= UMODE_CCONN_FULL;
# Line 3980  yyreduce: Line 3974  yyreduce:
3974    
3975    case 155:    case 155:
3976  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3977  #line 1049 "conf_parser.y"  #line 1043 "conf_parser.y"
3978      {      {
3979    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3980      block_state.modes.value |= UMODE_DEAF;      block_state.modes.value |= UMODE_DEAF;
# Line 3989  yyreduce: Line 3983  yyreduce:
3983    
3984    case 156:    case 156:
3985  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3986  #line 1053 "conf_parser.y"  #line 1047 "conf_parser.y"
3987      {      {
3988    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3989      block_state.modes.value |= UMODE_DEBUG;      block_state.modes.value |= UMODE_DEBUG;
# Line 3998  yyreduce: Line 3992  yyreduce:
3992    
3993    case 157:    case 157:
3994  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
3995  #line 1057 "conf_parser.y"  #line 1051 "conf_parser.y"
3996      {      {
3997    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
3998      block_state.modes.value |= UMODE_FULL;      block_state.modes.value |= UMODE_FULL;
# Line 4007  yyreduce: Line 4001  yyreduce:
4001    
4002    case 158:    case 158:
4003  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4004  #line 1061 "conf_parser.y"  #line 1055 "conf_parser.y"
4005      {      {
4006    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4007      block_state.modes.value |= UMODE_HIDDEN;      block_state.modes.value |= UMODE_HIDDEN;
# Line 4016  yyreduce: Line 4010  yyreduce:
4010    
4011    case 159:    case 159:
4012  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4013  #line 1065 "conf_parser.y"  #line 1059 "conf_parser.y"
4014      {      {
4015    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4016      block_state.modes.value |= UMODE_SKILL;      block_state.modes.value |= UMODE_SKILL;
# Line 4025  yyreduce: Line 4019  yyreduce:
4019    
4020    case 160:    case 160:
4021  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4022  #line 1069 "conf_parser.y"  #line 1063 "conf_parser.y"
4023      {      {
4024    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4025      block_state.modes.value |= UMODE_NCHANGE;      block_state.modes.value |= UMODE_NCHANGE;
# Line 4034  yyreduce: Line 4028  yyreduce:
4028    
4029    case 161:    case 161:
4030  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4031  #line 1073 "conf_parser.y"  #line 1067 "conf_parser.y"
4032      {      {
4033    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4034      block_state.modes.value |= UMODE_REJ;      block_state.modes.value |= UMODE_REJ;
# Line 4043  yyreduce: Line 4037  yyreduce:
4037    
4038    case 162:    case 162:
4039  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4040  #line 1077 "conf_parser.y"  #line 1071 "conf_parser.y"
4041      {      {
4042    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4043      block_state.modes.value |= UMODE_UNAUTH;      block_state.modes.value |= UMODE_UNAUTH;
# Line 4052  yyreduce: Line 4046  yyreduce:
4046    
4047    case 163:    case 163:
4048  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4049  #line 1081 "conf_parser.y"  #line 1075 "conf_parser.y"
4050      {      {
4051    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4052      block_state.modes.value |= UMODE_SPY;      block_state.modes.value |= UMODE_SPY;
# Line 4061  yyreduce: Line 4055  yyreduce:
4055    
4056    case 164:    case 164:
4057  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4058  #line 1085 "conf_parser.y"  #line 1079 "conf_parser.y"
4059      {      {
4060    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4061      block_state.modes.value |= UMODE_EXTERNAL;      block_state.modes.value |= UMODE_EXTERNAL;
# Line 4070  yyreduce: Line 4064  yyreduce:
4064    
4065    case 165:    case 165:
4066  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4067  #line 1089 "conf_parser.y"  #line 1083 "conf_parser.y"
4068      {      {
4069    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4070      block_state.modes.value |= UMODE_OPERWALL;      block_state.modes.value |= UMODE_OPERWALL;
# Line 4079  yyreduce: Line 4073  yyreduce:
4073    
4074    case 166:    case 166:
4075  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4076  #line 1093 "conf_parser.y"  #line 1087 "conf_parser.y"
4077      {      {
4078    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4079      block_state.modes.value |= UMODE_SERVNOTICE;      block_state.modes.value |= UMODE_SERVNOTICE;
# Line 4088  yyreduce: Line 4082  yyreduce:
4082    
4083    case 167:    case 167:
4084  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4085  #line 1097 "conf_parser.y"  #line 1091 "conf_parser.y"
4086      {      {
4087    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4088      block_state.modes.value |= UMODE_INVISIBLE;      block_state.modes.value |= UMODE_INVISIBLE;
# Line 4097  yyreduce: Line 4091  yyreduce:
4091    
4092    case 168:    case 168:
4093  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4094  #line 1101 "conf_parser.y"  #line 1095 "conf_parser.y"
4095      {      {
4096    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4097      block_state.modes.value |= UMODE_WALLOP;      block_state.modes.value |= UMODE_WALLOP;
# Line 4106  yyreduce: Line 4100  yyreduce:
4100    
4101    case 169:    case 169:
4102  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4103  #line 1105 "conf_parser.y"  #line 1099 "conf_parser.y"
4104      {      {
4105    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4106      block_state.modes.value |= UMODE_SOFTCALLERID;      block_state.modes.value |= UMODE_SOFTCALLERID;
# Line 4115  yyreduce: Line 4109  yyreduce:
4109    
4110    case 170:    case 170:
4111  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4112  #line 1109 "conf_parser.y"  #line 1103 "conf_parser.y"
4113      {      {
4114    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4115      block_state.modes.value |= UMODE_CALLERID;      block_state.modes.value |= UMODE_CALLERID;
# Line 4124  yyreduce: Line 4118  yyreduce:
4118    
4119    case 171:    case 171:
4120  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4121  #line 1113 "conf_parser.y"  #line 1107 "conf_parser.y"
4122      {      {
4123    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4124      block_state.modes.value |= UMODE_LOCOPS;      block_state.modes.value |= UMODE_LOCOPS;
# Line 4133  yyreduce: Line 4127  yyreduce:
4127    
4128    case 172:    case 172:
4129  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4130  #line 1119 "conf_parser.y"  #line 1113 "conf_parser.y"
4131      {      {
4132    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4133      block_state.port.value = 0;      block_state.port.value = 0;
# Line 4142  yyreduce: Line 4136  yyreduce:
4136    
4137    case 176:    case 176:
4138  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4139  #line 1126 "conf_parser.y"  #line 1120 "conf_parser.y"
4140      {      {
4141    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4142      block_state.port.value |= OPER_FLAG_GLOBAL_KILL;      block_state.port.value |= OPER_FLAG_GLOBAL_KILL;
# Line 4151  yyreduce: Line 4145  yyreduce:
4145    
4146    case 177:    case 177:
4147  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4148  #line 1130 "conf_parser.y"  #line 1124 "conf_parser.y"
4149      {      {
4150    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4151      block_state.port.value |= OPER_FLAG_REMOTE;      block_state.port.value |= OPER_FLAG_REMOTE;
# Line 4160  yyreduce: Line 4154  yyreduce:
4154    
4155    case 178:    case 178:
4156  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4157  #line 1134 "conf_parser.y"  #line 1128 "conf_parser.y"
4158      {      {
4159    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4160      block_state.port.value |= OPER_FLAG_K;      block_state.port.value |= OPER_FLAG_K;
# Line 4169  yyreduce: Line 4163  yyreduce:
4163    
4164    case 179:    case 179:
4165  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4166  #line 1138 "conf_parser.y"  #line 1132 "conf_parser.y"
4167      {      {
4168    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4169      block_state.port.value |= OPER_FLAG_UNKLINE;      block_state.port.value |= OPER_FLAG_UNKLINE;
# Line 4178  yyreduce: Line 4172  yyreduce:
4172    
4173    case 180:    case 180:
4174  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4175  #line 1142 "conf_parser.y"  #line 1136 "conf_parser.y"
4176      {      {
4177    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4178      block_state.port.value |= OPER_FLAG_DLINE;      block_state.port.value |= OPER_FLAG_DLINE;
# Line 4187  yyreduce: Line 4181  yyreduce:
4181    
4182    case 181:    case 181:
4183  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4184  #line 1146 "conf_parser.y"  #line 1140 "conf_parser.y"
4185      {      {
4186    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4187      block_state.port.value |= OPER_FLAG_UNDLINE;      block_state.port.value |= OPER_FLAG_UNDLINE;
# Line 4196  yyreduce: Line 4190  yyreduce:
4190    
4191    case 182:    case 182:
4192  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4193  #line 1150 "conf_parser.y"  #line 1144 "conf_parser.y"
4194      {      {
4195    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4196      block_state.port.value |= OPER_FLAG_X;      block_state.port.value |= OPER_FLAG_X;
# Line 4205  yyreduce: Line 4199  yyreduce:
4199    
4200    case 183:    case 183:
4201  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4202  #line 1154 "conf_parser.y"  #line 1148 "conf_parser.y"
4203      {      {
4204    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4205      block_state.port.value |= OPER_FLAG_GLINE;      block_state.port.value |= OPER_FLAG_GLINE;
# Line 4214  yyreduce: Line 4208  yyreduce:
4208    
4209    case 184:    case 184:
4210  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4211  #line 1158 "conf_parser.y"  #line 1152 "conf_parser.y"
4212      {      {
4213    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4214      block_state.port.value |= OPER_FLAG_DIE;      block_state.port.value |= OPER_FLAG_DIE;
# Line 4223  yyreduce: Line 4217  yyreduce:
4217    
4218    case 185:    case 185:
4219  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4220  #line 1162 "conf_parser.y"  #line 1156 "conf_parser.y"
4221      {      {
4222    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4223      block_state.port.value |= OPER_FLAG_RESTART;      block_state.port.value |= OPER_FLAG_RESTART;
# Line 4232  yyreduce: Line 4226  yyreduce:
4226    
4227    case 186:    case 186:
4228  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4229  #line 1166 "conf_parser.y"  #line 1160 "conf_parser.y"
4230      {      {
4231    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4232      block_state.port.value |= OPER_FLAG_REHASH;      block_state.port.value |= OPER_FLAG_REHASH;
# Line 4241  yyreduce: Line 4235  yyreduce:
4235    
4236    case 187:    case 187:
4237  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4238  #line 1170 "conf_parser.y"  #line 1164 "conf_parser.y"
4239      {      {
4240    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4241      block_state.port.value |= OPER_FLAG_ADMIN;      block_state.port.value |= OPER_FLAG_ADMIN;
# Line 4250  yyreduce: Line 4244  yyreduce:
4244    
4245    case 188:    case 188:
4246  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4247  #line 1174 "conf_parser.y"  #line 1168 "conf_parser.y"
4248      {      {
4249    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4250      block_state.port.value |= OPER_FLAG_N;      block_state.port.value |= OPER_FLAG_N;
# Line 4259  yyreduce: Line 4253  yyreduce:
4253    
4254    case 189:    case 189:
4255  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4256  #line 1178 "conf_parser.y"  #line 1172 "conf_parser.y"
4257      {      {
4258    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4259      block_state.port.value |= OPER_FLAG_OPERWALL;      block_state.port.value |= OPER_FLAG_OPERWALL;
# Line 4268  yyreduce: Line 4262  yyreduce:
4262    
4263    case 190:    case 190:
4264  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4265  #line 1182 "conf_parser.y"  #line 1176 "conf_parser.y"
4266      {      {
4267    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4268      block_state.port.value |= OPER_FLAG_GLOBOPS;      block_state.port.value |= OPER_FLAG_GLOBOPS;
# Line 4277  yyreduce: Line 4271  yyreduce:
4271    
4272    case 191:    case 191:
4273  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4274  #line 1186 "conf_parser.y"  #line 1180 "conf_parser.y"
4275      {      {
4276    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4277      block_state.port.value |= OPER_FLAG_OPER_SPY;      block_state.port.value |= OPER_FLAG_OPER_SPY;
# Line 4286  yyreduce: Line 4280  yyreduce:
4280    
4281    case 192:    case 192:
4282  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4283  #line 1190 "conf_parser.y"  #line 1184 "conf_parser.y"
4284      {      {
4285    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4286      block_state.port.value |= OPER_FLAG_REMOTEBAN;      block_state.port.value |= OPER_FLAG_REMOTEBAN;
# Line 4295  yyreduce: Line 4289  yyreduce:
4289    
4290    case 193:    case 193:
4291  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4292  #line 1194 "conf_parser.y"  #line 1188 "conf_parser.y"
4293      {      {
4294    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4295      block_state.port.value |= OPER_FLAG_SET;      block_state.port.value |= OPER_FLAG_SET;
# Line 4304  yyreduce: Line 4298  yyreduce:
4298    
4299    case 194:    case 194:
4300  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4301  #line 1198 "conf_parser.y"  #line 1192 "conf_parser.y"
4302      {      {
4303    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4304      block_state.port.value |= OPER_FLAG_MODULE;      block_state.port.value |= OPER_FLAG_MODULE;
# Line 4313  yyreduce: Line 4307  yyreduce:
4307    
4308    case 195:    case 195:
4309  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4310  #line 1208 "conf_parser.y"  #line 1202 "conf_parser.y"
4311      {      {
4312    if (conf_parser_ctx.pass == 1)    if (conf_parser_ctx.pass == 1)
4313    {      reset_block_state();
     yy_class = class_make();  
   }  
4314  }  }
4315      break;      break;
4316    
4317    case 196:    case 196:
4318  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4319  #line 1214 "conf_parser.y"  #line 1206 "conf_parser.y"
4320      {      {
4321    if (conf_parser_ctx.pass == 1)    struct ClassItem *class = NULL;
   {  
     struct ClassItem *class = NULL;  
   
     if (yy_class_name == NULL)  
       class_free(yy_class);  
     else  
     {  
       class = class_find(yy_class_name, 0);  
   
       if (class != NULL)                /* The class existed already */  
       {  
         int user_count = 0;  
4322    
4323          rebuild_cidr_class(class, yy_class);    if (conf_parser_ctx.pass != 1)
4324        break;
         user_count = class->ref_count;  
         memcpy(class, yy_class, sizeof(*class));  
         class->ref_count = user_count;  
         class->active = 1;  
   
         class_free(yy_class);  
4325    
4326          MyFree(class->name);            /* Allows case change of class name */    if (!block_state.class.buf[0])
4327          class->name = yy_class_name;      break;
       }  
       else      /* Brand new class */  
       {  
         MyFree(yy_class->name);          /* just in case it was allocated */  
         yy_class->name = yy_class_name;  
         yy_class->active = 1;  
       }  
     }  
4328    
4329      yy_class_name = NULL;    if (!(class = class_find(block_state.class.buf, 0)))
4330    }      class = class_make();
4331    
4332      class->active = 1;
4333      MyFree(class->name);
4334      class->name = xstrdup(block_state.class.buf);
4335      class->ping_freq = block_state.ping_freq.value;
4336      class->max_perip = block_state.max_perip.value;
4337      class->con_freq = block_state.con_freq.value;
4338      class->max_total = block_state.max_total.value;
4339      class->max_global = block_state.max_global.value;
4340      class->max_local = block_state.max_local.value;
4341      class->max_ident = block_state.max_ident.value;
4342      class->max_sendq = block_state.max_sendq.value;
4343      class->max_recvq = block_state.max_recvq.value;
4344    
4345      if (class->number_per_cidr && block_state.number_per_cidr.value)
4346        if ((class->cidr_bitlen_ipv4 && block_state.cidr_bitlen_ipv4.value) ||
4347            (class->cidr_bitlen_ipv6 && block_state.cidr_bitlen_ipv6.value))
4348          if ((class->cidr_bitlen_ipv4 != block_state.cidr_bitlen_ipv4.value) ||
4349              (class->cidr_bitlen_ipv6 != block_state.cidr_bitlen_ipv6.value))
4350            rebuild_cidr_list(class);
4351    
4352      class->cidr_bitlen_ipv4 = block_state.cidr_bitlen_ipv4.value;
4353      class->cidr_bitlen_ipv6 = block_state.cidr_bitlen_ipv6.value;
4354      class->number_per_cidr = block_state.number_per_cidr.value;
4355  }  }
4356      break;      break;
4357    
4358    case 213:    case 213:
4359  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4360  #line 1268 "conf_parser.y"  #line 1258 "conf_parser.y"
4361      {      {
4362    if (conf_parser_ctx.pass == 1)    if (conf_parser_ctx.pass == 1)
4363    {      strlcpy(block_state.class.buf, yylval.string, sizeof(block_state.class.buf));
     MyFree(yy_class_name);  
     yy_class_name = xstrdup(yylval.string);  
   }  
4364  }  }
4365      break;      break;
4366    
4367    case 214:    case 214:
4368  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4369  #line 1277 "conf_parser.y"  #line 1264 "conf_parser.y"
4370      {      {
4371    if (conf_parser_ctx.pass == 1)    if (conf_parser_ctx.pass == 1)
4372      yy_class->ping_freq = (yyvsp[(3) - (4)].number);      block_state.ping_freq.value = (yyvsp[(3) - (4)].number);
4373  }  }
4374      break;      break;
4375    
4376    case 215:    case 215:
4377  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4378  #line 1283 "conf_parser.y"  #line 1270 "conf_parser.y"
4379      {      {
4380    if (conf_parser_ctx.pass == 1)    if (conf_parser_ctx.pass == 1)
4381      yy_class->max_perip = (yyvsp[(3) - (4)].number);      block_state.max_perip.value = (yyvsp[(3) - (4)].number);
4382  }  }
4383      break;      break;
4384    
4385    case 216:    case 216:
4386  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4387  #line 1289 "conf_parser.y"  #line 1276 "conf_parser.y"
4388      {      {
4389    if (conf_parser_ctx.pass == 1)    if (conf_parser_ctx.pass == 1)
4390      yy_class->con_freq = (yyvsp[(3) - (4)].number);      block_state.con_freq.value = (yyvsp[(3) - (4)].number);
4391  }  }
4392      break;      break;
4393    
4394    case 217:    case 217:
4395  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4396  #line 1295 "conf_parser.y"  #line 1282 "conf_parser.y"
4397      {      {
4398    if (conf_parser_ctx.pass == 1)    if (conf_parser_ctx.pass == 1)
4399      yy_class->max_total = (yyvsp[(3) - (4)].number);      block_state.max_total.value = (yyvsp[(3) - (4)].number);
4400  }  }
4401      break;      break;
4402    
4403    case 218:    case 218:
4404  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4405  #line 1301 "conf_parser.y"  #line 1288 "conf_parser.y"
4406      {      {
4407    if (conf_parser_ctx.pass == 1)    if (conf_parser_ctx.pass == 1)
4408      yy_class->max_global = (yyvsp[(3) - (4)].number);      block_state.max_global.value = (yyvsp[(3) - (4)].number);
4409  }  }
4410      break;      break;
4411    
4412    case 219:    case 219:
4413  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4414  #line 1307 "conf_parser.y"  #line 1294 "conf_parser.y"
4415      {      {
4416    if (conf_parser_ctx.pass == 1)    if (conf_parser_ctx.pass == 1)
4417      yy_class->max_local = (yyvsp[(3) - (4)].number);      block_state.max_local.value = (yyvsp[(3) - (4)].number);
4418  }  }
4419      break;      break;
4420    
4421    case 220:    case 220:
4422  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4423  #line 1313 "conf_parser.y"  #line 1300 "conf_parser.y"
4424      {      {
4425    if (conf_parser_ctx.pass == 1)    if (conf_parser_ctx.pass == 1)
4426      yy_class->max_ident = (yyvsp[(3) - (4)].number);      block_state.max_ident.value = (yyvsp[(3) - (4)].number);
4427  }  }
4428      break;      break;
4429    
4430    case 221:    case 221:
4431  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4432  #line 1319 "conf_parser.y"  #line 1306 "conf_parser.y"
4433      {      {
4434    if (conf_parser_ctx.pass == 1)    if (conf_parser_ctx.pass == 1)
4435      yy_class->max_sendq = (yyvsp[(3) - (4)].number);      block_state.max_sendq.value = (yyvsp[(3) - (4)].number);
4436  }  }
4437      break;      break;
4438    
4439    case 222:    case 222:
4440  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4441  #line 1325 "conf_parser.y"  #line 1312 "conf_parser.y"
4442      {      {
4443    if (conf_parser_ctx.pass == 1)    if (conf_parser_ctx.pass == 1)
4444      if ((yyvsp[(3) - (4)].number) >= CLIENT_FLOOD_MIN && (yyvsp[(3) - (4)].number) <= CLIENT_FLOOD_MAX)      if ((yyvsp[(3) - (4)].number) >= CLIENT_FLOOD_MIN && (yyvsp[(3) - (4)].number) <= CLIENT_FLOOD_MAX)
4445        yy_class->max_recvq = (yyvsp[(3) - (4)].number);        block_state.max_recvq.value = (yyvsp[(3) - (4)].number);
4446  }  }
4447      break;      break;
4448    
4449    case 223:    case 223:
4450  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4451  #line 1332 "conf_parser.y"  #line 1319 "conf_parser.y"
4452      {      {
4453    if (conf_parser_ctx.pass == 1)    if (conf_parser_ctx.pass == 1)
4454      yy_class->cidr_bitlen_ipv4 = (yyvsp[(3) - (4)].number) > 32 ? 32 : (yyvsp[(3) - (4)].number);      block_state.cidr_bitlen_ipv4.value = (yyvsp[(3) - (4)].number) > 32 ? 32 : (yyvsp[(3) - (4)].number);
4455  }  }
4456      break;      break;
4457    
4458    case 224:    case 224:
4459  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4460  #line 1338 "conf_parser.y"  #line 1325 "conf_parser.y"
4461      {      {
4462    if (conf_parser_ctx.pass == 1)    if (conf_parser_ctx.pass == 1)
4463      yy_class->cidr_bitlen_ipv6 = (yyvsp[(3) - (4)].number) > 128 ? 128 : (yyvsp[(3) - (4)].number);      block_state.cidr_bitlen_ipv6.value = (yyvsp[(3) - (4)].number) > 128 ? 128 : (yyvsp[(3) - (4)].number);
4464  }  }
4465      break;      break;
4466    
4467    case 225:    case 225:
4468  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4469  #line 1344 "conf_parser.y"  #line 1331 "conf_parser.y"
4470      {      {
4471    if (conf_parser_ctx.pass == 1)    if (conf_parser_ctx.pass == 1)
4472      yy_class->number_per_cidr = (yyvsp[(3) - (4)].number);      block_state.number_per_cidr.value = (yyvsp[(3) - (4)].number);
4473  }  }
4474      break;      break;
4475    
4476    case 226:    case 226:
4477  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4478  #line 1353 "conf_parser.y"  #line 1340 "conf_parser.y"
4479      {      {
4480    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4481      reset_block_state();      reset_block_state();
# Line 4497  yyreduce: Line 4484  yyreduce:
4484    
4485    case 228:    case 228:
4486  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4487  #line 1359 "conf_parser.y"  #line 1346 "conf_parser.y"
4488      {      {
4489    block_state.flags.value = 0;    block_state.flags.value = 0;
4490  }  }
# Line 4505  yyreduce: Line 4492  yyreduce:
4492    
4493    case 232:    case 232:
4494  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4495  #line 1365 "conf_parser.y"  #line 1352 "conf_parser.y"
4496      {      {
4497    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4498      block_state.flags.value |= LISTENER_SSL;      block_state.flags.value |= LISTENER_SSL;
# Line 4514  yyreduce: Line 4501  yyreduce:
4501    
4502    case 233:    case 233:
4503  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4504  #line 1369 "conf_parser.y"  #line 1356 "conf_parser.y"
4505      {      {
4506    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4507      block_state.flags.value |=LISTENER_HIDDEN;      block_state.flags.value |= LISTENER_HIDDEN;
4508  }  }
4509      break;      break;
4510    
4511    case 234:    case 234:
4512  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4513  #line 1373 "conf_parser.y"  #line 1360 "conf_parser.y"
4514      {      {
4515    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4516     block_state.flags.value |=LISTENER_SERVER;     block_state.flags.value |= LISTENER_SERVER;
4517  }  }
4518      break;      break;
4519    
4520    case 242:    case 242:
4521  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4522  #line 1381 "conf_parser.y"  #line 1368 "conf_parser.y"
4523      { block_state.flags.value |= 0; }      { block_state.flags.value |= 0; }
4524      break;      break;
4525    
4526    case 246:    case 246:
4527  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4528  #line 1386 "conf_parser.y"  #line 1373 "conf_parser.y"
4529      {      {
4530    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4531    {    {
# Line 4557  yyreduce: Line 4544  yyreduce:
4544    
4545    case 247:    case 247:
4546  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4547  #line 1400 "conf_parser.y"  #line 1387 "conf_parser.y"
4548      {      {
4549    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4550    {    {
# Line 4580  yyreduce: Line 4567  yyreduce:
4567    
4568    case 248:    case 248:
4569  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4570  #line 1420 "conf_parser.y"  #line 1407 "conf_parser.y"
4571      {      {
4572    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4573      strlcpy(block_state.addr.buf, yylval.string, sizeof(block_state.addr.buf));      strlcpy(block_state.addr.buf, yylval.string, sizeof(block_state.addr.buf));
# Line 4589  yyreduce: Line 4576  yyreduce:
4576    
4577    case 249:    case 249:
4578  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4579  #line 1426 "conf_parser.y"  #line 1413 "conf_parser.y"
4580      {      {
4581    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4582      strlcpy(block_state.addr.buf, yylval.string, sizeof(block_state.addr.buf));      strlcpy(block_state.addr.buf, yylval.string, sizeof(block_state.addr.buf));
# Line 4598  yyreduce: Line 4585  yyreduce:
4585    
4586    case 250:    case 250:
4587  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4588  #line 1435 "conf_parser.y"  #line 1422 "conf_parser.y"
4589      {      {
4590    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4591      reset_block_state();      reset_block_state();
# Line 4607  yyreduce: Line 4594  yyreduce:
4594    
4595    case 251:    case 251:
4596  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4597  #line 1439 "conf_parser.y"  #line 1426 "conf_parser.y"
4598      {      {
4599    dlink_node *ptr = NULL;    dlink_node *ptr = NULL;
4600    
# Line 4621  yyreduce: Line 4608  yyreduce:
4608    
4609      nuh.nuhmask  = ptr->data;      nuh.nuhmask  = ptr->data;
4610      nuh.nickptr  = NULL;      nuh.nickptr  = NULL;
4611      nuh.userptr  = userbuf;      nuh.userptr  = block_state.user.buf;
4612      nuh.hostptr  = hostbuf;      nuh.hostptr  = block_state.host.buf;
4613      nuh.nicksize = 0;      nuh.nicksize = 0;
4614      nuh.usersize = sizeof(userbuf);      nuh.usersize = sizeof(block_state.user.buf);
4615      nuh.hostsize = sizeof(hostbuf);      nuh.hostsize = sizeof(block_state.host.buf);
4616      split_nuh(&nuh);      split_nuh(&nuh);
4617    
4618      conf        = conf_make(CONF_CLIENT);      conf        = conf_make(CONF_CLIENT);
4619      conf->user  = xstrdup(collapse(userbuf));      conf->user  = xstrdup(collapse(block_state.user.buf));
4620      conf->host  = xstrdup(collapse(hostbuf));      conf->host  = xstrdup(collapse(block_state.host.buf));
4621    
4622      if (block_state.pass.buf[0])      if (block_state.rpass.buf[0])
4623        conf->passwd = xstrdup(block_state.pass.buf);        conf->passwd = xstrdup(block_state.rpass.buf);
4624      if (block_state.name.buf[0])      if (block_state.name.buf[0])
4625        conf->passwd = xstrdup(block_state.name.buf);        conf->passwd = xstrdup(block_state.name.buf);
4626    
# Line 4648  yyreduce: Line 4635  yyreduce:
4635    
4636    case 263:    case 263:
4637  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4638  #line 1482 "conf_parser.y"  #line 1469 "conf_parser.y"
4639      {      {
4640    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4641      dlinkAdd(xstrdup(yylval.string), make_dlink_node(), &block_state.mask.list);      dlinkAdd(xstrdup(yylval.string), make_dlink_node(), &block_state.mask.list);
# Line 4657  yyreduce: Line 4644  yyreduce:
4644    
4645    case 264:    case 264:
4646  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4647  #line 1488 "conf_parser.y"  #line 1475 "conf_parser.y"
4648      {      {
4649    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4650      strlcpy(block_state.pass.buf, yylval.string, sizeof(block_state.pass.buf));      strlcpy(block_state.rpass.buf, yylval.string, sizeof(block_state.rpass.buf));
4651  }  }
4652      break;      break;
4653    
4654    case 265:    case 265:
4655  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4656  #line 1494 "conf_parser.y"  #line 1481 "conf_parser.y"
4657      {      {
4658    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4659      strlcpy(block_state.class.buf, yylval.string, sizeof(block_state.class.buf));      strlcpy(block_state.class.buf, yylval.string, sizeof(block_state.class.buf));
# Line 4675  yyreduce: Line 4662  yyreduce:
4662    
4663    case 266:    case 266:
4664  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4665  #line 1500 "conf_parser.y"  #line 1487 "conf_parser.y"
4666      {      {
4667    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4668    {    {
# Line 4689  yyreduce: Line 4676  yyreduce:
4676    
4677    case 267:    case 267:
4678  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4679  #line 1511 "conf_parser.y"  #line 1498 "conf_parser.y"
4680      {      {
4681    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4682      block_state.flags.value = 0;      block_state.flags.value = 0;
# Line 4698  yyreduce: Line 4685  yyreduce:
4685    
4686    case 271:    case 271:
4687  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4688  #line 1518 "conf_parser.y"  #line 1505 "conf_parser.y"
4689      {      {
4690    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4691      block_state.flags.value |= CONF_FLAGS_SPOOF_NOTICE;      block_state.flags.value |= CONF_FLAGS_SPOOF_NOTICE;
# Line 4707  yyreduce: Line 4694  yyreduce:
4694    
4695    case 272:    case 272:
4696  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4697  #line 1522 "conf_parser.y"  #line 1509 "conf_parser.y"
4698      {      {
4699    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4700      block_state.flags.value |= CONF_FLAGS_NOLIMIT;      block_state.flags.value |= CONF_FLAGS_NOLIMIT;
# Line 4716  yyreduce: Line 4703  yyreduce:
4703    
4704    case 273:    case 273:
4705  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4706  #line 1526 "conf_parser.y"  #line 1513 "conf_parser.y"
4707      {      {
4708    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4709      block_state.flags.value |= CONF_FLAGS_EXEMPTKLINE;      block_state.flags.value |= CONF_FLAGS_EXEMPTKLINE;
# Line 4725  yyreduce: Line 4712  yyreduce:
4712    
4713    case 274:    case 274:
4714  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4715  #line 1530 "conf_parser.y"  #line 1517 "conf_parser.y"
4716      {      {
4717    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4718      block_state.flags.value |= CONF_FLAGS_NEED_IDENTD;      block_state.flags.value |= CONF_FLAGS_NEED_IDENTD;
# Line 4734  yyreduce: Line 4721  yyreduce:
4721    
4722    case 275:    case 275:
4723  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4724  #line 1534 "conf_parser.y"  #line 1521 "conf_parser.y"
4725      {      {
4726    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4727      block_state.flags.value |= CONF_FLAGS_CAN_FLOOD;      block_state.flags.value |= CONF_FLAGS_CAN_FLOOD;
# Line 4743  yyreduce: Line 4730  yyreduce:
4730    
4731    case 276:    case 276:
4732  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4733  #line 1538 "conf_parser.y"  #line 1525 "conf_parser.y"
4734      {      {
4735    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4736      block_state.flags.value |= CONF_FLAGS_NO_TILDE;      block_state.flags.value |= CONF_FLAGS_NO_TILDE;
# Line 4752  yyreduce: Line 4739  yyreduce:
4739    
4740    case 277:    case 277:
4741  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4742  #line 1542 "conf_parser.y"  #line 1529 "conf_parser.y"
4743      {      {
4744    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4745      block_state.flags.value |= CONF_FLAGS_EXEMPTGLINE;      block_state.flags.value |= CONF_FLAGS_EXEMPTGLINE;
# Line 4761  yyreduce: Line 4748  yyreduce:
4748    
4749    case 278:    case 278:
4750  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4751  #line 1546 "conf_parser.y"  #line 1533 "conf_parser.y"
4752      {      {
4753    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4754      block_state.flags.value |= CONF_FLAGS_EXEMPTRESV;      block_state.flags.value |= CONF_FLAGS_EXEMPTRESV;
# Line 4770  yyreduce: Line 4757  yyreduce:
4757    
4758    case 279:    case 279:
4759  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4760  #line 1550 "conf_parser.y"  #line 1537 "conf_parser.y"
4761      {      {
4762    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4763      block_state.flags.value |= CONF_FLAGS_NEED_PASSWORD;      block_state.flags.value |= CONF_FLAGS_NEED_PASSWORD;
# Line 4779  yyreduce: Line 4766  yyreduce:
4766    
4767    case 280:    case 280:
4768  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4769  #line 1556 "conf_parser.y"  #line 1543 "conf_parser.y"
4770      {      {
4771    if (conf_parser_ctx.pass != 2)    if (conf_parser_ctx.pass != 2)
4772      break;      break;
# Line 4796  yyreduce: Line 4783  yyreduce:
4783    
4784    case 281:    case 281:
4785  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4786  #line 1570 "conf_parser.y"  #line 1557 "conf_parser.y"
4787      {      {
4788    if (conf_parser_ctx.pass != 2)    if (conf_parser_ctx.pass != 2)
4789      break;      break;
# Line 4808  yyreduce: Line 4795  yyreduce:
4795    
4796    case 282:    case 282:
4797  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4798  #line 1579 "conf_parser.y"  #line 1566 "conf_parser.y"
4799      {      {
4800    if (conf_parser_ctx.pass != 2)    if (conf_parser_ctx.pass != 2)
4801      break;      break;
4802    
4803    block_state.flags.value |= CONF_FLAGS_REDIR;    block_state.flags.value |= CONF_FLAGS_REDIR;
4804    block_state.port.value = (yyvsp[(3) - (4)].number);    block_state.port.value = (yyvsp[(3) - (4)].number);
4805  }  }
# Line 4819  yyreduce: Line 4807  yyreduce:
4807    
4808    case 283:    case 283:
4809  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4810  #line 1591 "conf_parser.y"  #line 1579 "conf_parser.y"
4811      {      {
4812    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass != 2)
   {  
     MyFree(resv_reason);  
     resv_reason = NULL;  
   }  
 }  
4813      break;      break;
4814    
4815    case 284:    reset_block_state();
4816  /* Line 1813 of yacc.c  */    strlcpy(block_state.rpass.buf, CONF_NOREASON, sizeof(block_state.rpass.buf));
 #line 1598 "conf_parser.y"  
     {  
   if (conf_parser_ctx.pass == 2)  
   {  
     MyFree(resv_reason);  
     resv_reason = NULL;  
   }  
4817  }  }
4818      break;      break;
4819    
4820    case 291:    case 291:
4821  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4822  #line 1610 "conf_parser.y"  #line 1591 "conf_parser.y"
4823      {      {
4824    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4825    {      strlcpy(block_state.rpass.buf, yylval.string, sizeof(block_state.rpass.buf));
     MyFree(resv_reason);  
     resv_reason = xstrdup(yylval.string);  
   }  
4826  }  }
4827      break;      break;
4828    
4829    case 292:    case 292:
4830  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4831  #line 1619 "conf_parser.y"  #line 1597 "conf_parser.y"
4832      {      {
4833    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass != 2)
4834    {      break;
     if (IsChanPrefix(*yylval.string))  
     {  
       char def_reason[] = "No reason";  
4835    
4836        create_channel_resv(yylval.string, resv_reason != NULL ? resv_reason : def_reason, 1);    if (IsChanPrefix(*yylval.string))
4837      }      create_channel_resv(yylval.string, block_state.rpass.buf, 1);
   }  
   /* ignore it for now.. but we really should make a warning if  
    * its an erroneous name --fl_ */  
4838  }  }
4839      break;      break;
4840    
4841    case 293:    case 293:
4842  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4843  #line 1634 "conf_parser.y"  #line 1606 "conf_parser.y"
4844      {      {
4845    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4846    {      create_nick_resv(yylval.string, block_state.rpass.buf, 1);
     char def_reason[] = "No reason";  
   
     create_nick_resv(yylval.string, resv_reason != NULL ? resv_reason : def_reason, 1);  
   }  
4847  }  }
4848      break;      break;
4849    
4850    case 299:    case 299:
4851  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4852  #line 1652 "conf_parser.y"  #line 1620 "conf_parser.y"
4853      {      {
4854    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4855    {    {
4856      if (valid_servname(yylval.string))      if (valid_servname(yylval.string))
4857      {      {
4858        yy_conf = conf_make(CONF_SERVICE);        struct MaskItem *conf = conf_make(CONF_SERVICE);
4859        yy_conf->name = xstrdup(yylval.string);        conf->name = xstrdup(yylval.string);
4860      }      }
4861    }    }
4862  }  }
# Line 4901  yyreduce: Line 4864  yyreduce:
4864    
4865    case 300:    case 300:
4866  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4867  #line 1667 "conf_parser.y"  #line 1635 "conf_parser.y"
4868      {      {
4869    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass != 2)
4870    {      break;
4871      yy_conf = conf_make(CONF_ULINE);  
4872      yy_conf->flags = SHARED_ALL;    reset_block_state();
4873    }  
4874      strlcpy(block_state.name.buf, "*", sizeof(block_state.name.buf));
4875      strlcpy(block_state.user.buf, "*", sizeof(block_state.user.buf));
4876      strlcpy(block_state.host.buf, "*", sizeof(block_state.host.buf));
4877      block_state.flags.value = SHARED_ALL;
4878  }  }
4879      break;      break;
4880    
4881    case 301:    case 301:
4882  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4883  #line 1674 "conf_parser.y"  #line 1646 "conf_parser.y"
4884      {      {
4885    if (conf_parser_ctx.pass == 2)    struct MaskItem *conf = NULL;
4886    {  
4887      yy_conf = NULL;    if (conf_parser_ctx.pass != 2)
4888    }      break;
4889    
4890      conf = conf_make(CONF_ULINE);
4891      conf->flags = block_state.flags.value;
4892      conf->name = xstrdup(block_state.name.buf);
4893      conf->user = xstrdup(block_state.user.buf);
4894      conf->user = xstrdup(block_state.host.buf);
4895  }  }
4896      break;      break;
4897    
4898    case 308:    case 308:
4899  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4900  #line 1685 "conf_parser.y"  #line 1663 "conf_parser.y"
4901      {      {
4902    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4903    {      strlcpy(block_state.name.buf, yylval.string, sizeof(block_state.name.buf));
     MyFree(yy_conf->name);  
     DupString(yy_conf->name, yylval.string);  
   }  
4904  }  }
4905      break;      break;
4906    
4907    case 309:    case 309:
4908  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4909  #line 1694 "conf_parser.y"  #line 1669 "conf_parser.y"
4910      {      {
4911    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4912    {    {
# Line 4944  yyreduce: Line 4914  yyreduce:
4914    
4915      nuh.nuhmask  = yylval.string;      nuh.nuhmask  = yylval.string;
4916      nuh.nickptr  = NULL;      nuh.nickptr  = NULL;
4917      nuh.userptr  = userbuf;      nuh.userptr  = block_state.user.buf;
4918      nuh.hostptr  = hostbuf;      nuh.hostptr  = block_state.host.buf;
4919    
4920      nuh.nicksize = 0;      nuh.nicksize = 0;
4921      nuh.usersize = sizeof(userbuf);      nuh.usersize = sizeof(block_state.user.buf);
4922      nuh.hostsize = sizeof(hostbuf);      nuh.hostsize = sizeof(block_state.host.buf);
4923    
4924      split_nuh(&nuh);      split_nuh(&nuh);
   
     DupString(yy_conf->user, userbuf);  
     DupString(yy_conf->host, hostbuf);  
4925    }    }
4926  }  }
4927      break;      break;
4928    
4929    case 310:    case 310:
4930  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4931  #line 1716 "conf_parser.y"  #line 1688 "conf_parser.y"
4932      {      {
4933    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4934      yy_conf->flags = 0;      block_state.flags.value = 0;
4935  }  }
4936      break;      break;
4937    
4938    case 314:    case 314:
4939  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4940  #line 1723 "conf_parser.y"  #line 1695 "conf_parser.y"
4941      {      {
4942    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4943      yy_conf->flags |= SHARED_KLINE;      block_state.flags.value |= SHARED_KLINE;
4944  }  }
4945      break;      break;
4946    
4947    case 315:    case 315:
4948  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4949  #line 1727 "conf_parser.y"  #line 1699 "conf_parser.y"
4950      {      {
4951    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4952      yy_conf->flags |= SHARED_UNKLINE;      block_state.flags.value |= SHARED_UNKLINE;
4953  }  }
4954      break;      break;
4955    
4956    case 316:    case 316:
4957  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4958  #line 1731 "conf_parser.y"  #line 1703 "conf_parser.y"
4959      {      {
4960    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4961      yy_conf->flags |= SHARED_DLINE;      block_state.flags.value |= SHARED_DLINE;
4962  }  }
4963      break;      break;
4964    
4965    case 317:    case 317:
4966  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4967  #line 1735 "conf_parser.y"  #line 1707 "conf_parser.y"
4968      {      {
4969    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4970      yy_conf->flags |= SHARED_UNDLINE;      block_state.flags.value |= SHARED_UNDLINE;
4971  }  }
4972      break;      break;
4973    
4974    case 318:    case 318:
4975  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4976  #line 1739 "conf_parser.y"  #line 1711 "conf_parser.y"
4977      {      {
4978    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4979      yy_conf->flags |= SHARED_XLINE;      block_state.flags.value |= SHARED_XLINE;
4980  }  }
4981      break;      break;
4982    
4983    case 319:    case 319:
4984  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4985  #line 1743 "conf_parser.y"  #line 1715 "conf_parser.y"
4986      {      {
4987    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4988      yy_conf->flags |= SHARED_UNXLINE;      block_state.flags.value |= SHARED_UNXLINE;
4989  }  }
4990      break;      break;
4991    
4992    case 320:    case 320:
4993  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
4994  #line 1747 "conf_parser.y"  #line 1719 "conf_parser.y"
4995      {      {
4996    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
4997      yy_conf->flags |= SHARED_RESV;      block_state.flags.value |= SHARED_RESV;
4998  }  }
4999      break;      break;
5000    
5001    case 321:    case 321:
5002  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5003  #line 1751 "conf_parser.y"  #line 1723 "conf_parser.y"
5004      {      {
5005    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5006      yy_conf->flags |= SHARED_UNRESV;      block_state.flags.value |= SHARED_UNRESV;
5007  }  }
5008      break;      break;
5009    
5010    case 322:    case 322:
5011  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5012  #line 1755 "conf_parser.y"  #line 1727 "conf_parser.y"
5013      {      {
5014    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5015      yy_conf->flags |= SHARED_LOCOPS;      block_state.flags.value |= SHARED_LOCOPS;
5016  }  }
5017      break;      break;
5018    
5019    case 323:    case 323:
5020  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5021  #line 1759 "conf_parser.y"  #line 1731 "conf_parser.y"
5022      {      {
5023    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5024      yy_conf->flags = SHARED_ALL;      block_state.flags.value = SHARED_ALL;
5025  }  }
5026      break;      break;
5027    
5028    case 324:    case 324:
5029  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5030  #line 1768 "conf_parser.y"  #line 1740 "conf_parser.y"
5031      {      {
5032    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass != 2)
5033    {      break;
5034      yy_conf = conf_make(CONF_CLUSTER);  
5035    }    reset_block_state();
5036    
5037      strlcpy(block_state.name.buf, "*", sizeof(block_state.name.buf));
5038      block_state.flags.value = SHARED_ALL;
5039  }  }
5040      break;      break;
5041    
5042    case 325:    case 325:
5043  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5044  #line 1774 "conf_parser.y"  #line 1749 "conf_parser.y"
5045      {      {
5046    if (conf_parser_ctx.pass == 2)    struct MaskItem *conf = NULL;
5047    {  
5048      if (yy_conf->name == NULL)    if (conf_parser_ctx.pass != 2)
5049        DupString(yy_conf->name, "*");      break;
5050      yy_conf = NULL;  
5051    }    conf = conf_make(CONF_CLUSTER);
5052      conf->flags = block_state.flags.value;
5053      conf->name = xstrdup(block_state.name.buf);
5054  }  }
5055      break;      break;
5056    
5057    case 331:    case 331:
5058  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5059  #line 1787 "conf_parser.y"  #line 1764 "conf_parser.y"
5060      {      {
5061    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5062      DupString(yy_conf->name, yylval.string);      strlcpy(block_state.name.buf, yylval.string, sizeof(block_state.name.buf));
5063  }  }
5064      break;      break;
5065    
5066    case 332:    case 332:
5067  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5068  #line 1793 "conf_parser.y"  #line 1770 "conf_parser.y"
5069      {      {
5070    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5071      yy_conf->flags = 0;      block_state.flags.value = 0;
5072  }  }
5073      break;      break;
5074    
5075    case 336:    case 336:
5076  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5077  #line 1800 "conf_parser.y"  #line 1777 "conf_parser.y"
5078      {      {
5079    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5080      yy_conf->flags |= SHARED_KLINE;      block_state.flags.value |= SHARED_KLINE;
5081  }  }
5082      break;      break;
5083    
5084    case 337:    case 337:
5085  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5086  #line 1804 "conf_parser.y"  #line 1781 "conf_parser.y"
5087      {      {
5088    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5089      yy_conf->flags |= SHARED_UNKLINE;      block_state.flags.value |= SHARED_UNKLINE;
5090  }  }
5091      break;      break;
5092    
5093    case 338:    case 338:
5094  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5095  #line 1808 "conf_parser.y"  #line 1785 "conf_parser.y"
5096      {      {
5097    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5098      yy_conf->flags |= SHARED_DLINE;      block_state.flags.value |= SHARED_DLINE;
5099  }  }
5100      break;      break;
5101    
5102    case 339:    case 339:
5103  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5104  #line 1812 "conf_parser.y"  #line 1789 "conf_parser.y"
5105      {      {
5106    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5107      yy_conf->flags |= SHARED_UNDLINE;      block_state.flags.value |= SHARED_UNDLINE;
5108  }  }
5109      break;      break;
5110    
5111    case 340:    case 340:
5112  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5113  #line 1816 "conf_parser.y"  #line 1793 "conf_parser.y"
5114      {      {
5115    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5116      yy_conf->flags |= SHARED_XLINE;      block_state.flags.value |= SHARED_XLINE;
5117  }  }
5118      break;      break;
5119    
5120    case 341:    case 341:
5121  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5122  #line 1820 "conf_parser.y"  #line 1797 "conf_parser.y"
5123      {      {
5124    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5125      yy_conf->flags |= SHARED_UNXLINE;      block_state.flags.value |= SHARED_UNXLINE;
5126  }  }
5127      break;      break;
5128    
5129    case 342:    case 342:
5130  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5131  #line 1824 "conf_parser.y"  #line 1801 "conf_parser.y"
5132      {      {
5133    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5134      yy_conf->flags |= SHARED_RESV;      block_state.flags.value |= SHARED_RESV;
5135  }  }
5136      break;      break;
5137    
5138    case 343:    case 343:
5139  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5140  #line 1828 "conf_parser.y"  #line 1805 "conf_parser.y"
5141      {      {
5142    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5143      yy_conf->flags |= SHARED_UNRESV;      block_state.flags.value |= SHARED_UNRESV;
5144  }  }
5145      break;      break;
5146    
5147    case 344:    case 344:
5148  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5149  #line 1832 "conf_parser.y"  #line 1809 "conf_parser.y"
5150      {      {
5151    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5152      yy_conf->flags |= SHARED_LOCOPS;      block_state.flags.value |= SHARED_LOCOPS;
5153  }  }
5154      break;      break;
5155    
5156    case 345:    case 345:
5157  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5158  #line 1836 "conf_parser.y"  #line 1813 "conf_parser.y"
5159      {      {
5160    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5161      yy_conf->flags = SHARED_ALL;      block_state.flags.value = SHARED_ALL;
5162  }  }
5163      break;      break;
5164    
5165    case 346:    case 346:
5166  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5167  #line 1845 "conf_parser.y"  #line 1822 "conf_parser.y"
5168      {      {
   if (conf_parser_ctx.pass == 2)  
   {  
     yy_conf = conf_make(CONF_SERVER);  
5169    
5170      /* defaults */    if (conf_parser_ctx.pass != 2)
5171      yy_conf->port = PORTNUM;      break;
5172    }  
5173    else    reset_block_state();
5174    {    block_state.port.value = PORTNUM;
     MyFree(class_name);  
     class_name = NULL;  
   }  
5175  }  }
5176      break;      break;
5177    
5178    case 347:    case 347:
5179  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5180  #line 1859 "conf_parser.y"  #line 1830 "conf_parser.y"
5181      {      {
5182    if (conf_parser_ctx.pass == 2)    struct MaskItem *conf = NULL;
5183      struct addrinfo hints, *res;
5184    
5185      if (conf_parser_ctx.pass != 2)
5186        break;
5187    
5188      if (!(block_state.name.buf[0] ||
5189            block_state.host.buf[0]))
5190        break;
5191    
5192      if (!(block_state.rpass.buf[0] ||
5193            block_state.spass.buf[0]))
5194        break;
5195    
5196      if (has_wildcards(block_state.name.buf) ||
5197          has_wildcards(block_state.host.buf))
5198        break;
5199    
5200      conf = conf_make(CONF_SERVER);
5201      conf->port = block_state.port.value;
5202      conf->flags = block_state.flags.value;
5203      conf->aftype = block_state.aftype.value;
5204      conf->host = xstrdup(block_state.host.buf);
5205      conf->name = xstrdup(block_state.name.buf);
5206      conf->passwd = xstrdup(block_state.rpass.buf);
5207      conf->spasswd = xstrdup(block_state.spass.buf);
5208      conf->cipher_list = xstrdup(block_state.ciph.buf);
5209    
5210      dlinkMoveList(&block_state.leaf.list, &conf->leaf_list);
5211      dlinkMoveList(&block_state.hub.list, &conf->hub_list);
5212    
5213      if (block_state.bind.buf[0])
5214    {    {
5215      if (yy_conf->host && yy_conf->passwd && yy_conf->spasswd)      memset(&hints, 0, sizeof(hints));
5216      {  
5217        if (conf_add_server(yy_conf, class_name) == -1)      hints.ai_family   = AF_UNSPEC;
5218          conf_free(yy_conf);      hints.ai_socktype = SOCK_STREAM;
5219      }      hints.ai_flags    = AI_PASSIVE | AI_NUMERICHOST;
5220    
5221        if (getaddrinfo(block_state.bind.buf, NULL, &hints, &res))
5222          ilog(LOG_TYPE_IRCD, "Invalid netmask for server vhost(%s)", block_state.bind.buf);
5223      else      else
5224      {      {
5225        if (yy_conf->name != NULL)        assert(res != NULL);
       {  
         if (yy_conf->host == NULL)  
           yyerror("Ignoring connect block -- missing host");  
         else if (!yy_conf->passwd || !yy_conf->spasswd)  
           yyerror("Ignoring connect block -- missing password");  
       }  
5226    
5227        /* XXX        memcpy(&conf->bind, res->ai_addr, res->ai_addrlen);
5228         * This fixes a try_connections() core (caused by invalid class_ptr        conf->bind.ss.ss_family = res->ai_family;
5229         * pointers) reported by metalrock. That's an ugly fix, but there        conf->bind.ss_len = res->ai_addrlen;
5230         * is currently no better way. The entire config subsystem needs an        freeaddrinfo(res);
        * rewrite ASAP. make_conf_item() shouldn't really add things onto  
        * a doubly linked list immediately without any sanity checks!  -Michael  
        */  
       conf_free(yy_conf);  
5231      }      }
   
     MyFree(class_name);  
     class_name = NULL;  
     yy_conf = NULL;  
5232    }    }
5233    
5234      conf_add_class_to_conf(conf, block_state.class.buf);
5235      lookup_confhost(conf);
5236  }  }
5237      break;      break;
5238    
5239    case 364:    case 364:
5240  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5241  #line 1902 "conf_parser.y"  #line 1896 "conf_parser.y"
5242      {      {
5243    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5244    {      strlcpy(block_state.name.buf, yylval.string, sizeof(block_state.name.buf));
     MyFree(yy_conf->name);  
     DupString(yy_conf->name, yylval.string);  
   }  
5245  }  }
5246      break;      break;
5247    
5248    case 365:    case 365:
5249  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5250  #line 1911 "conf_parser.y"  #line 1902 "conf_parser.y"
5251      {      {
5252    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5253    {      strlcpy(block_state.host.buf, yylval.string, sizeof(block_state.host.buf));
     MyFree(yy_conf->host);  
     DupString(yy_conf->host, yylval.string);  
   }  
5254  }  }
5255      break;      break;
5256    
5257    case 366:    case 366:
5258  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5259  #line 1920 "conf_parser.y"  #line 1908 "conf_parser.y"
5260      {      {
5261    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5262    {      strlcpy(block_state.bind.buf, yylval.string, sizeof(block_state.bind.buf));
     struct addrinfo hints, *res;  
   
     memset(&hints, 0, sizeof(hints));  
   
     hints.ai_family   = AF_UNSPEC;  
     hints.ai_socktype = SOCK_STREAM;  
     hints.ai_flags    = AI_PASSIVE | AI_NUMERICHOST;  
   
     if (getaddrinfo(yylval.string, NULL, &hints, &res))  
       ilog(LOG_TYPE_IRCD, "Invalid netmask for server vhost(%s)", yylval.string);  
     else  
     {  
       assert(res != NULL);  
   
       memcpy(&yy_conf->bind, res->ai_addr, res->ai_addrlen);  
       yy_conf->bind.ss.ss_family = res->ai_family;  
       yy_conf->bind.ss_len = res->ai_addrlen;  
       freeaddrinfo(res);  
     }  
   }  
5263  }  }
5264      break;      break;
5265    
5266    case 367:    case 367:
5267  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5268  #line 1946 "conf_parser.y"  #line 1914 "conf_parser.y"
5269      {      {
5270    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass != 2)
5271    {      break;
     if ((yyvsp[(3) - (4)].string)[0] == ':')  
       yyerror("Server passwords cannot begin with a colon");  
     else if (strchr((yyvsp[(3) - (4)].string), ' ') != NULL)  
       yyerror("Server passwords cannot contain spaces");  
     else {  
       if (yy_conf->spasswd != NULL)  
         memset(yy_conf->spasswd, 0, strlen(yy_conf->spasswd));  
5272    
5273        MyFree(yy_conf->spasswd);    if ((yyvsp[(3) - (4)].string)[0] == ':')
5274        DupString(yy_conf->spasswd, yylval.string);      yyerror("Server passwords cannot begin with a colon");
5275      }    else if (strchr((yyvsp[(3) - (4)].string), ' ') != NULL)
5276    }      yyerror("Server passwords cannot contain spaces");
5277      else
5278        strlcpy(block_state.spass.buf, yylval.string, sizeof(block_state.spass.buf));
5279  }  }
5280      break;      break;
5281    
5282    case 368:    case 368:
5283  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5284  #line 1964 "conf_parser.y"  #line 1927 "conf_parser.y"
5285      {      {
5286    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass != 2)
5287    {      break;
     if ((yyvsp[(3) - (4)].string)[0] == ':')  
       yyerror("Server passwords cannot begin with a colon");  
     else if (strchr((yyvsp[(3) - (4)].string), ' ') != NULL)  
       yyerror("Server passwords cannot contain spaces");  
     else {  
       if (yy_conf->passwd != NULL)  
         memset(yy_conf->passwd, 0, strlen(yy_conf->passwd));  
5288    
5289        MyFree(yy_conf->passwd);    if ((yyvsp[(3) - (4)].string)[0] == ':')
5290        DupString(yy_conf->passwd, yylval.string);      yyerror("Server passwords cannot begin with a colon");
5291      }    else if (strchr((yyvsp[(3) - (4)].string), ' ') != NULL)
5292    }      yyerror("Server passwords cannot contain spaces");
5293      else
5294        strlcpy(block_state.rpass.buf, yylval.string, sizeof(block_state.rpass.buf));
5295  }  }
5296      break;      break;
5297    
5298    case 369:    case 369:
5299  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5300  #line 1982 "conf_parser.y"  #line 1940 "conf_parser.y"
5301      {      {
5302    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5303      yy_conf->port = (yyvsp[(3) - (4)].number);      block_state.port.value = (yyvsp[(3) - (4)].number);
5304  }  }
5305      break;      break;
5306    
5307    case 370:    case 370:
5308  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5309  #line 1988 "conf_parser.y"  #line 1946 "conf_parser.y"
5310      {      {
5311    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5312      yy_conf->aftype = AF_INET;      block_state.aftype.value = AF_INET;
5313  }  }
5314      break;      break;
5315    
5316    case 371:    case 371:
5317  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5318  #line 1992 "conf_parser.y"  #line 1950 "conf_parser.y"
5319      {      {
5320  #ifdef IPV6  #ifdef IPV6
5321    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5322      yy_conf->aftype = AF_INET6;      block_state.aftype.value = AF_INET6;
5323  #endif  #endif
5324  }  }
5325      break;      break;
5326    
5327    case 372:    case 372:
5328  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5329  #line 2000 "conf_parser.y"  #line 1958 "conf_parser.y"
5330      {      {
5331    /* XXX */
5332  }  }
5333      break;      break;
5334    
5335    case 376:    case 376:
5336  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5337  #line 2005 "conf_parser.y"  #line 1964 "conf_parser.y"
5338      {      {
5339    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5340      SetConfAllowAutoConn(yy_conf);      block_state.flags.value |= CONF_FLAGS_ALLOW_AUTO_CONN;
5341  }  }
5342      break;      break;
5343    
5344    case 377:    case 377:
5345  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5346  #line 2009 "conf_parser.y"  #line 1968 "conf_parser.y"
5347      {      {
5348    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5349      SetConfSSL(yy_conf);      block_state.flags.value |= CONF_FLAGS_SSL;
5350  }  }
5351      break;      break;
5352    
5353    case 378:    case 378:
5354  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5355  #line 2015 "conf_parser.y"  #line 1974 "conf_parser.y"
5356      {      {
5357    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5358    {    {
5359      if (yylval.number)      if (yylval.number)
5360        yy_conf->flags |= CONF_FLAGS_ENCRYPTED;        block_state.flags.value |= CONF_FLAGS_ENCRYPTED;
5361      else      else
5362        yy_conf->flags &= ~CONF_FLAGS_ENCRYPTED;        block_state.flags.value &= ~CONF_FLAGS_ENCRYPTED;
5363    }    }
5364  }  }
5365      break;      break;
5366    
5367    case 379:    case 379:
5368  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5369  #line 2026 "conf_parser.y"  #line 1985 "conf_parser.y"
5370      {      {
5371    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5372    {      dlinkAdd(xstrdup(yylval.string), make_dlink_node(), &block_state.hub.list);
     char *mask = xstrdup(yylval.string);  
   
     dlinkAdd(mask, make_dlink_node(), &yy_conf->hub_list);  
   }  
5373  }  }
5374      break;      break;
5375    
5376    case 380:    case 380:
5377  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5378  #line 2036 "conf_parser.y"  #line 1991 "conf_parser.y"
5379      {      {
5380    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5381    {      dlinkAdd(xstrdup(yylval.string), make_dlink_node(), &block_state.leaf.list);
     char *mask;  
   
     DupString(mask, yylval.string);  
     dlinkAdd(mask, make_dlink_node(), &yy_conf->leaf_list);  
   }  
5382  }  }
5383      break;      break;
5384    
5385    case 381:    case 381:
5386  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5387  #line 2047 "conf_parser.y"  #line 1997 "conf_parser.y"
5388      {      {
5389    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5390    {      strlcpy(block_state.class.buf, yylval.string, sizeof(block_state.class.buf));
     MyFree(class_name);  
     DupString(class_name, yylval.string);  
   }  
5391  }  }
5392      break;      break;
5393    
5394    case 382:    case 382:
5395  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5396  #line 2056 "conf_parser.y"  #line 2003 "conf_parser.y"
5397      {      {
5398  #ifdef HAVE_LIBCRYPTO  #ifdef HAVE_LIBCRYPTO
5399    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5400    {      strlcpy(block_state.ciph.buf, yylval.string, sizeof(block_state.ciph.buf));
     MyFree(yy_conf->cipher_list);  
     DupString(yy_conf->cipher_list, yylval.string);  
   }  
5401  #else  #else
5402    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5403      yyerror("Ignoring connect::ciphers -- no OpenSSL support");      yyerror("Ignoring connect::ciphers -- no OpenSSL support");
# Line 5468  yyreduce: Line 5407  yyreduce:
5407    
5408    case 383:    case 383:
5409  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5410  #line 2074 "conf_parser.y"  #line 2018 "conf_parser.y"
5411      {      {
5412    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5413    {      reset_block_state();
     userbuf[0] = hostbuf[0] = reasonbuf[0] = '\0';  
     regex_ban = 0;  
   }  
5414  }  }
5415      break;      break;
5416    
5417    case 384:    case 384:
5418  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5419  #line 2081 "conf_parser.y"  #line 2022 "conf_parser.y"
5420      {      {
5421    if (conf_parser_ctx.pass == 2)    struct MaskItem *conf = NULL;
   {  
     struct MaskItem *conf = NULL;  
5422    
5423      if (userbuf[0] && hostbuf[0])    if (conf_parser_ctx.pass != 2)
5424      {      break;
       if (regex_ban)  
       {  
 #ifdef HAVE_LIBPCRE  
         void *exp_user = NULL;  
         void *exp_host = NULL;  
         const char *errptr = NULL;  
5425    
5426          if (!(exp_user = ircd_pcre_compile(userbuf, &errptr)) ||    if (!block_state.user.buf[0] ||
5427              !(exp_host = ircd_pcre_compile(hostbuf, &errptr)))        !block_state.host.buf[0])
5428          {      break;
           ilog(LOG_TYPE_IRCD, "Failed to add regular expression based K-Line: %s",  
                errptr);  
           break;  
         }  
5429    
         conf = conf_make(CONF_RKLINE);  
         conf->regexuser = exp_user;  
         conf->regexhost = exp_host;  
5430    
5431          conf->user = xstrdup(userbuf);    if (block_state.port.value == 1)
5432          conf->host = xstrdup(hostbuf);    {
5433    #ifdef HAVE_LIBPCRE
5434        void *exp_user = NULL;
5435        void *exp_host = NULL;
5436        const char *errptr = NULL;
5437    
5438        if (!(exp_user = ircd_pcre_compile(block_state.user.buf, &errptr)) ||
5439            !(exp_host = ircd_pcre_compile(block_state.host.buf, &errptr)))
5440        {
5441          ilog(LOG_TYPE_IRCD, "Failed to add regular expression based K-Line: %s",
5442               errptr);
5443          break;
5444        }
5445    
5446          if (reasonbuf[0])      conf = conf_make(CONF_RKLINE);
5447            conf->reason = xstrdup(reasonbuf);      conf->regexuser = exp_user;
5448          else      conf->regexhost = exp_host;
5449            conf->reason = xstrdup(CONF_NOREASON);  
5450        conf->user = xstrdup(block_state.user.buf);
5451        conf->host = xstrdup(block_state.host.buf);
5452    
5453        if (block_state.rpass.buf[0])
5454          conf->reason = xstrdup(block_state.rpass.buf);
5455        else
5456          conf->reason = xstrdup(CONF_NOREASON);
5457  #else  #else
5458          ilog(LOG_TYPE_IRCD, "Failed to add regular expression based K-Line: no PCRE support");      ilog(LOG_TYPE_IRCD, "Failed to add regular expression based K-Line: no PCRE support");
5459          break;      break;
5460  #endif  #endif
5461        }    }
5462        else    else
5463        {    {
5464          conf = conf_make(CONF_KLINE);      conf = conf_make(CONF_KLINE);
5465    
5466          conf->user = xstrdup(userbuf);      conf->user = xstrdup(block_state.user.buf);
5467          conf->host = xstrdup(hostbuf);      conf->host = xstrdup(block_state.host.buf);
5468    
5469          if (reasonbuf[0])      if (block_state.rpass.buf[0])
5470            conf->reason = xstrdup(reasonbuf);        conf->reason = xstrdup(block_state.rpass.buf);
5471          else      else
5472            conf->reason = xstrdup(CONF_NOREASON);        conf->reason = xstrdup(CONF_NOREASON);
5473          add_conf_by_address(CONF_KLINE, conf);      add_conf_by_address(CONF_KLINE, conf);
       }  
     }  
5474    }    }
5475  }  }
5476      break;      break;
5477    
5478    case 385:    case 385:
5479  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5480  #line 2137 "conf_parser.y"  #line 2080 "conf_parser.y"
5481      {      {
5482      if (conf_parser_ctx.pass == 2)
5483        block_state.port.value = 0;
5484  }  }
5485      break;      break;
5486    
5487    case 389:    case 389:
5488  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5489  #line 2142 "conf_parser.y"  #line 2087 "conf_parser.y"
5490      {      {
5491    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5492      regex_ban = 1;      block_state.port.value = 1;
5493  }  }
5494      break;      break;
5495    
5496    case 396:    case 396:
5497  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5498  #line 2151 "conf_parser.y"  #line 2096 "conf_parser.y"
5499      {      {
5500    
5501    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5502    {    {
5503      struct split_nuh_item nuh;      struct split_nuh_item nuh;
5504    
5505      nuh.nuhmask  = yylval.string;      nuh.nuhmask  = yylval.string;
5506      nuh.nickptr  = NULL;      nuh.nickptr  = NULL;
5507      nuh.userptr  = userbuf;      nuh.userptr  = block_state.user.buf;
5508      nuh.hostptr  = hostbuf;      nuh.hostptr  = block_state.host.buf;
5509    
5510      nuh.nicksize = 0;      nuh.nicksize = 0;
5511      nuh.usersize = sizeof(userbuf);      nuh.usersize = sizeof(block_state.user.buf);
5512      nuh.hostsize = sizeof(hostbuf);      nuh.hostsize = sizeof(block_state.host.buf);
5513    
5514      split_nuh(&nuh);      split_nuh(&nuh);
5515    }    }
# Line 5577  yyreduce: Line 5518  yyreduce:
5518    
5519    case 397:    case 397:
5520  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5521  #line 2170 "conf_parser.y"  #line 2116 "conf_parser.y"
5522      {      {
5523    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5524      strlcpy(reasonbuf, yylval.string, sizeof(reasonbuf));      strlcpy(block_state.rpass.buf, yylval.string, sizeof(block_state.rpass.buf));
5525  }  }
5526      break;      break;
5527    
5528    case 398:    case 398:
5529  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5530  #line 2179 "conf_parser.y"  #line 2125 "conf_parser.y"
5531      {      {
5532    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5533      reset_block_state();      reset_block_state();
# Line 5595  yyreduce: Line 5536  yyreduce:
5536    
5537    case 399:    case 399:
5538  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5539  #line 2183 "conf_parser.y"  #line 2129 "conf_parser.y"
5540      {      {
5541    struct MaskItem *conf = NULL;    struct MaskItem *conf = NULL;
5542    
# Line 5610  yyreduce: Line 5551  yyreduce:
5551      conf = conf_make(CONF_DLINE);      conf = conf_make(CONF_DLINE);
5552      conf->host = xstrdup(block_state.addr.buf);      conf->host = xstrdup(block_state.addr.buf);
5553    
5554      if (block_state.pass.buf[0])      if (block_state.rpass.buf[0])
5555        conf->reason = xstrdup(block_state.pass.buf);        conf->reason = xstrdup(block_state.rpass.buf);
5556      else      else
5557        conf->reason = xstrdup(CONF_NOREASON);        conf->reason = xstrdup(CONF_NOREASON);
5558      add_conf_by_address(CONF_DLINE, conf);      add_conf_by_address(CONF_DLINE, conf);
# Line 5621  yyreduce: Line 5562  yyreduce:
5562    
5563    case 405:    case 405:
5564  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5565  #line 2209 "conf_parser.y"  #line 2155 "conf_parser.y"
5566      {      {
5567    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5568      strlcpy(block_state.addr.buf, yylval.string, sizeof(block_state.addr.buf));      strlcpy(block_state.addr.buf, yylval.string, sizeof(block_state.addr.buf));
# Line 5630  yyreduce: Line 5571  yyreduce:
5571    
5572    case 406:    case 406:
5573  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5574  #line 2215 "conf_parser.y"  #line 2161 "conf_parser.y"
5575      {      {
5576    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5577      strlcpy(block_state.pass.buf, yylval.string, sizeof(block_state.pass.buf));      strlcpy(block_state.rpass.buf, yylval.string, sizeof(block_state.rpass.buf));
5578  }  }
5579      break;      break;
5580    
5581    case 412:    case 412:
5582  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5583  #line 2229 "conf_parser.y"  #line 2175 "conf_parser.y"
5584      {      {
5585    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5586    {    {
# Line 5656  yyreduce: Line 5597  yyreduce:
5597    
5598    case 413:    case 413:
5599  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5600  #line 2246 "conf_parser.y"  #line 2192 "conf_parser.y"
5601      {      {
5602    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5603      reset_block_state();      reset_block_state();
# Line 5665  yyreduce: Line 5606  yyreduce:
5606    
5607    case 414:    case 414:
5608  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5609  #line 2250 "conf_parser.y"  #line 2196 "conf_parser.y"
5610      {      {
5611    struct MaskItem *conf = NULL;    struct MaskItem *conf = NULL;
5612    
# Line 5700  yyreduce: Line 5641  yyreduce:
5641    
5642    conf->name = xstrdup(block_state.name.buf);    conf->name = xstrdup(block_state.name.buf);
5643    
5644    if (block_state.pass.buf[0])    if (block_state.rpass.buf[0])
5645      conf->reason = xstrdup(block_state.pass.buf);      conf->reason = xstrdup(block_state.rpass.buf);
5646    else    else
5647      conf->reason = xstrdup(CONF_NOREASON);      conf->reason = xstrdup(CONF_NOREASON);
5648  }  }
# Line 5709  yyreduce: Line 5650  yyreduce:
5650    
5651    case 415:    case 415:
5652  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5653  #line 2291 "conf_parser.y"  #line 2237 "conf_parser.y"
5654      {      {
5655    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5656      block_state.port.value = 0;      block_state.port.value = 0;
# Line 5718  yyreduce: Line 5659  yyreduce:
5659    
5660    case 419:    case 419:
5661  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5662  #line 2298 "conf_parser.y"  #line 2244 "conf_parser.y"
5663      {      {
5664    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5665      block_state.port.value = 1;      block_state.port.value = 1;
# Line 5727  yyreduce: Line 5668  yyreduce:
5668    
5669    case 426:    case 426:
5670  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5671  #line 2307 "conf_parser.y"  #line 2253 "conf_parser.y"
5672      {      {
5673    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5674      strlcpy(block_state.name.buf, yylval.string, sizeof(block_state.name.buf));      strlcpy(block_state.name.buf, yylval.string, sizeof(block_state.name.buf));
# Line 5736  yyreduce: Line 5677  yyreduce:
5677    
5678    case 427:    case 427:
5679  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5680  #line 2313 "conf_parser.y"  #line 2259 "conf_parser.y"
5681      {      {
5682    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5683      strlcpy(block_state.pass.buf, yylval.string, sizeof(block_state.pass.buf));      strlcpy(block_state.rpass.buf, yylval.string, sizeof(block_state.rpass.buf));
5684  }  }
5685      break;      break;
5686    
5687    case 481:    case 481:
5688  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5689  #line 2358 "conf_parser.y"  #line 2304 "conf_parser.y"
5690      {      {
5691    ConfigFileEntry.max_watch = (yyvsp[(3) - (4)].number);    ConfigFileEntry.max_watch = (yyvsp[(3) - (4)].number);
5692  }  }
# Line 5753  yyreduce: Line 5694  yyreduce:
5694    
5695    case 482:    case 482:
5696  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5697  #line 2363 "conf_parser.y"  #line 2309 "conf_parser.y"
5698      {      {
5699    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5700      ConfigFileEntry.glines = yylval.number;      ConfigFileEntry.glines = yylval.number;
# Line 5762  yyreduce: Line 5703  yyreduce:
5703    
5704    case 483:    case 483:
5705  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5706  #line 2369 "conf_parser.y"  #line 2315 "conf_parser.y"
5707      {      {
5708    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5709      ConfigFileEntry.gline_time = (yyvsp[(3) - (4)].number);      ConfigFileEntry.gline_time = (yyvsp[(3) - (4)].number);
# Line 5771  yyreduce: Line 5712  yyreduce:
5712    
5713    case 484:    case 484:
5714  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5715  #line 2375 "conf_parser.y"  #line 2321 "conf_parser.y"
5716      {      {
5717    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5718      ConfigFileEntry.gline_request_time = (yyvsp[(3) - (4)].number);      ConfigFileEntry.gline_request_time = (yyvsp[(3) - (4)].number);
# Line 5780  yyreduce: Line 5721  yyreduce:
5721    
5722    case 485:    case 485:
5723  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5724  #line 2381 "conf_parser.y"  #line 2327 "conf_parser.y"
5725      {      {
5726    ConfigFileEntry.gline_min_cidr = (yyvsp[(3) - (4)].number);    ConfigFileEntry.gline_min_cidr = (yyvsp[(3) - (4)].number);
5727  }  }
# Line 5788  yyreduce: Line 5729  yyreduce:
5729    
5730    case 486:    case 486:
5731  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5732  #line 2386 "conf_parser.y"  #line 2332 "conf_parser.y"
5733      {      {
5734    ConfigFileEntry.gline_min_cidr6 = (yyvsp[(3) - (4)].number);    ConfigFileEntry.gline_min_cidr6 = (yyvsp[(3) - (4)].number);
5735  }  }
# Line 5796  yyreduce: Line 5737  yyreduce:
5737    
5738    case 487:    case 487:
5739  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5740  #line 2391 "conf_parser.y"  #line 2337 "conf_parser.y"
5741      {      {
5742    ConfigFileEntry.tkline_expire_notices = yylval.number;    ConfigFileEntry.tkline_expire_notices = yylval.number;
5743  }  }
# Line 5804  yyreduce: Line 5745  yyreduce:
5745    
5746    case 488:    case 488:
5747  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5748  #line 2396 "conf_parser.y"  #line 2342 "conf_parser.y"
5749      {      {
5750    ConfigFileEntry.kill_chase_time_limit = (yyvsp[(3) - (4)].number);    ConfigFileEntry.kill_chase_time_limit = (yyvsp[(3) - (4)].number);
5751  }  }
# Line 5812  yyreduce: Line 5753  yyreduce:
5753    
5754    case 489:    case 489:
5755  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5756  #line 2401 "conf_parser.y"  #line 2347 "conf_parser.y"
5757      {      {
5758    ConfigFileEntry.hide_spoof_ips = yylval.number;    ConfigFileEntry.hide_spoof_ips = yylval.number;
5759  }  }
# Line 5820  yyreduce: Line 5761  yyreduce:
5761    
5762    case 490:    case 490:
5763  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5764  #line 2406 "conf_parser.y"  #line 2352 "conf_parser.y"
5765      {      {
5766    ConfigFileEntry.ignore_bogus_ts = yylval.number;    ConfigFileEntry.ignore_bogus_ts = yylval.number;
5767  }  }
# Line 5828  yyreduce: Line 5769  yyreduce:
5769    
5770    case 491:    case 491:
5771  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5772  #line 2411 "conf_parser.y"  #line 2357 "conf_parser.y"
5773      {      {
5774    ConfigFileEntry.disable_remote = yylval.number;    ConfigFileEntry.disable_remote = yylval.number;
5775  }  }
# Line 5836  yyreduce: Line 5777  yyreduce:
5777    
5778    case 492:    case 492:
5779  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5780  #line 2416 "conf_parser.y"  #line 2362 "conf_parser.y"
5781      {      {
5782    ConfigFileEntry.failed_oper_notice = yylval.number;    ConfigFileEntry.failed_oper_notice = yylval.number;
5783  }  }
# Line 5844  yyreduce: Line 5785  yyreduce:
5785    
5786    case 493:    case 493:
5787  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5788  #line 2421 "conf_parser.y"  #line 2367 "conf_parser.y"
5789      {      {
5790    ConfigFileEntry.anti_nick_flood = yylval.number;    ConfigFileEntry.anti_nick_flood = yylval.number;
5791  }  }
# Line 5852  yyreduce: Line 5793  yyreduce:
5793    
5794    case 494:    case 494:
5795  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5796  #line 2426 "conf_parser.y"  #line 2372 "conf_parser.y"
5797      {      {
5798    ConfigFileEntry.max_nick_time = (yyvsp[(3) - (4)].number);    ConfigFileEntry.max_nick_time = (yyvsp[(3) - (4)].number);
5799  }  }
# Line 5860  yyreduce: Line 5801  yyreduce:
5801    
5802    case 495:    case 495:
5803  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5804  #line 2431 "conf_parser.y"  #line 2377 "conf_parser.y"
5805      {      {
5806    ConfigFileEntry.max_nick_changes = (yyvsp[(3) - (4)].number);    ConfigFileEntry.max_nick_changes = (yyvsp[(3) - (4)].number);
5807  }  }
# Line 5868  yyreduce: Line 5809  yyreduce:
5809    
5810    case 496:    case 496:
5811  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5812  #line 2436 "conf_parser.y"  #line 2382 "conf_parser.y"
5813      {      {
5814    ConfigFileEntry.max_accept = (yyvsp[(3) - (4)].number);    ConfigFileEntry.max_accept = (yyvsp[(3) - (4)].number);
5815  }  }
# Line 5876  yyreduce: Line 5817  yyreduce:
5817    
5818    case 497:    case 497:
5819  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5820  #line 2441 "conf_parser.y"  #line 2387 "conf_parser.y"
5821      {      {
5822    ConfigFileEntry.anti_spam_exit_message_time = (yyvsp[(3) - (4)].number);    ConfigFileEntry.anti_spam_exit_message_time = (yyvsp[(3) - (4)].number);
5823  }  }
# Line 5884  yyreduce: Line 5825  yyreduce:
5825    
5826    case 498:    case 498:
5827  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5828  #line 2446 "conf_parser.y"  #line 2392 "conf_parser.y"
5829      {      {
5830    ConfigFileEntry.ts_warn_delta = (yyvsp[(3) - (4)].number);    ConfigFileEntry.ts_warn_delta = (yyvsp[(3) - (4)].number);
5831  }  }
# Line 5892  yyreduce: Line 5833  yyreduce:
5833    
5834    case 499:    case 499:
5835  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5836  #line 2451 "conf_parser.y"  #line 2397 "conf_parser.y"
5837      {      {
5838    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5839      ConfigFileEntry.ts_max_delta = (yyvsp[(3) - (4)].number);      ConfigFileEntry.ts_max_delta = (yyvsp[(3) - (4)].number);
# Line 5901  yyreduce: Line 5842  yyreduce:
5842    
5843    case 500:    case 500:
5844  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5845  #line 2457 "conf_parser.y"  #line 2403 "conf_parser.y"
5846      {      {
5847    if (((yyvsp[(3) - (4)].number) > 0) && conf_parser_ctx.pass == 1)    if (((yyvsp[(3) - (4)].number) > 0) && conf_parser_ctx.pass == 1)
5848    {    {
# Line 5915  yyreduce: Line 5856  yyreduce:
5856    
5857    case 501:    case 501:
5858  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5859  #line 2468 "conf_parser.y"  #line 2414 "conf_parser.y"
5860      {      {
5861    ConfigFileEntry.invisible_on_connect = yylval.number;    ConfigFileEntry.invisible_on_connect = yylval.number;
5862  }  }
# Line 5923  yyreduce: Line 5864  yyreduce:
5864    
5865    case 502:    case 502:
5866  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5867  #line 2473 "conf_parser.y"  #line 2419 "conf_parser.y"
5868      {      {
5869    ConfigFileEntry.warn_no_nline = yylval.number;    ConfigFileEntry.warn_no_nline = yylval.number;
5870  }  }
# Line 5931  yyreduce: Line 5872  yyreduce:
5872    
5873    case 503:    case 503:
5874  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5875  #line 2478 "conf_parser.y"  #line 2424 "conf_parser.y"
5876      {      {
5877    ConfigFileEntry.stats_e_disabled = yylval.number;    ConfigFileEntry.stats_e_disabled = yylval.number;
5878  }  }
# Line 5939  yyreduce: Line 5880  yyreduce:
5880    
5881    case 504:    case 504:
5882  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5883  #line 2483 "conf_parser.y"  #line 2429 "conf_parser.y"
5884      {      {
5885    ConfigFileEntry.stats_o_oper_only = yylval.number;    ConfigFileEntry.stats_o_oper_only = yylval.number;
5886  }  }
# Line 5947  yyreduce: Line 5888  yyreduce:
5888    
5889    case 505:    case 505:
5890  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5891  #line 2488 "conf_parser.y"  #line 2434 "conf_parser.y"
5892      {      {
5893    ConfigFileEntry.stats_P_oper_only = yylval.number;    ConfigFileEntry.stats_P_oper_only = yylval.number;
5894  }  }
# Line 5955  yyreduce: Line 5896  yyreduce:
5896    
5897    case 506:    case 506:
5898  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5899  #line 2493 "conf_parser.y"  #line 2439 "conf_parser.y"
5900      {      {
5901    ConfigFileEntry.stats_k_oper_only = 2 * yylval.number;    ConfigFileEntry.stats_k_oper_only = 2 * yylval.number;
5902  }  }
# Line 5963  yyreduce: Line 5904  yyreduce:
5904    
5905    case 507:    case 507:
5906  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5907  #line 2496 "conf_parser.y"  #line 2442 "conf_parser.y"
5908      {      {
5909    ConfigFileEntry.stats_k_oper_only = 1;    ConfigFileEntry.stats_k_oper_only = 1;
5910  }  }
# Line 5971  yyreduce: Line 5912  yyreduce:
5912    
5913    case 508:    case 508:
5914  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5915  #line 2501 "conf_parser.y"  #line 2447 "conf_parser.y"
5916      {      {
5917    ConfigFileEntry.stats_i_oper_only = 2 * yylval.number;    ConfigFileEntry.stats_i_oper_only = 2 * yylval.number;
5918  }  }
# Line 5979  yyreduce: Line 5920  yyreduce:
5920    
5921    case 509:    case 509:
5922  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5923  #line 2504 "conf_parser.y"  #line 2450 "conf_parser.y"
5924      {      {
5925    ConfigFileEntry.stats_i_oper_only = 1;    ConfigFileEntry.stats_i_oper_only = 1;
5926  }  }
# Line 5987  yyreduce: Line 5928  yyreduce:
5928    
5929    case 510:    case 510:
5930  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5931  #line 2509 "conf_parser.y"  #line 2455 "conf_parser.y"
5932      {      {
5933    ConfigFileEntry.pace_wait = (yyvsp[(3) - (4)].number);    ConfigFileEntry.pace_wait = (yyvsp[(3) - (4)].number);
5934  }  }
# Line 5995  yyreduce: Line 5936  yyreduce:
5936    
5937    case 511:    case 511:
5938  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5939  #line 2514 "conf_parser.y"  #line 2460 "conf_parser.y"
5940      {      {
5941    ConfigFileEntry.caller_id_wait = (yyvsp[(3) - (4)].number);    ConfigFileEntry.caller_id_wait = (yyvsp[(3) - (4)].number);
5942  }  }
# Line 6003  yyreduce: Line 5944  yyreduce:
5944    
5945    case 512:    case 512:
5946  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5947  #line 2519 "conf_parser.y"  #line 2465 "conf_parser.y"
5948      {      {
5949    ConfigFileEntry.opers_bypass_callerid = yylval.number;    ConfigFileEntry.opers_bypass_callerid = yylval.number;
5950  }  }
# Line 6011  yyreduce: Line 5952  yyreduce:
5952    
5953    case 513:    case 513:
5954  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5955  #line 2524 "conf_parser.y"  #line 2470 "conf_parser.y"
5956      {      {
5957    ConfigFileEntry.pace_wait_simple = (yyvsp[(3) - (4)].number);    ConfigFileEntry.pace_wait_simple = (yyvsp[(3) - (4)].number);
5958  }  }
# Line 6019  yyreduce: Line 5960  yyreduce:
5960    
5961    case 514:    case 514:
5962  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5963  #line 2529 "conf_parser.y"  #line 2475 "conf_parser.y"
5964      {      {
5965    ConfigFileEntry.short_motd = yylval.number;    ConfigFileEntry.short_motd = yylval.number;
5966  }  }
# Line 6027  yyreduce: Line 5968  yyreduce:
5968    
5969    case 515:    case 515:
5970  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5971  #line 2534 "conf_parser.y"  #line 2480 "conf_parser.y"
5972      {      {
5973    ConfigFileEntry.no_oper_flood = yylval.number;    ConfigFileEntry.no_oper_flood = yylval.number;
5974  }  }
# Line 6035  yyreduce: Line 5976  yyreduce:
5976    
5977    case 516:    case 516:
5978  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5979  #line 2539 "conf_parser.y"  #line 2485 "conf_parser.y"
5980      {      {
5981    ConfigFileEntry.true_no_oper_flood = yylval.number;    ConfigFileEntry.true_no_oper_flood = yylval.number;
5982  }  }
# Line 6043  yyreduce: Line 5984  yyreduce:
5984    
5985    case 517:    case 517:
5986  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5987  #line 2544 "conf_parser.y"  #line 2490 "conf_parser.y"
5988      {      {
5989    ConfigFileEntry.oper_pass_resv = yylval.number;    ConfigFileEntry.oper_pass_resv = yylval.number;
5990  }  }
# Line 6051  yyreduce: Line 5992  yyreduce:
5992    
5993    case 518:    case 518:
5994  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
5995  #line 2549 "conf_parser.y"  #line 2495 "conf_parser.y"
5996      {      {
5997    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
5998    {    {
# Line 6065  yyreduce: Line 6006  yyreduce:
6006    
6007    case 519:    case 519:
6008  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6009  #line 2560 "conf_parser.y"  #line 2506 "conf_parser.y"
6010      {      {
6011    ConfigFileEntry.dots_in_ident = (yyvsp[(3) - (4)].number);    ConfigFileEntry.dots_in_ident = (yyvsp[(3) - (4)].number);
6012  }  }
# Line 6073  yyreduce: Line 6014  yyreduce:
6014    
6015    case 520:    case 520:
6016  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6017  #line 2565 "conf_parser.y"  #line 2511 "conf_parser.y"
6018      {      {
6019    ConfigFileEntry.max_targets = (yyvsp[(3) - (4)].number);    ConfigFileEntry.max_targets = (yyvsp[(3) - (4)].number);
6020  }  }
# Line 6081  yyreduce: Line 6022  yyreduce:
6022    
6023    case 521:    case 521:
6024  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6025  #line 2570 "conf_parser.y"  #line 2516 "conf_parser.y"
6026      {      {
6027    ConfigFileEntry.use_egd = yylval.number;    ConfigFileEntry.use_egd = yylval.number;
6028  }  }
# Line 6089  yyreduce: Line 6030  yyreduce:
6030    
6031    case 522:    case 522:
6032  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6033  #line 2575 "conf_parser.y"  #line 2521 "conf_parser.y"
6034      {      {
6035    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
6036    {    {
# Line 6101  yyreduce: Line 6042  yyreduce:
6042    
6043    case 523:    case 523:
6044  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6045  #line 2584 "conf_parser.y"  #line 2530 "conf_parser.y"
6046      {      {
6047    if (conf_parser_ctx.pass == 2 && valid_servname(yylval.string))    if (conf_parser_ctx.pass == 2 && valid_servname(yylval.string))
6048    {    {
# Line 6113  yyreduce: Line 6054  yyreduce:
6054    
6055    case 524:    case 524:
6056  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6057  #line 2593 "conf_parser.y"  #line 2539 "conf_parser.y"
6058      {      {
6059    ConfigFileEntry.ping_cookie = yylval.number;    ConfigFileEntry.ping_cookie = yylval.number;
6060  }  }
# Line 6121  yyreduce: Line 6062  yyreduce:
6062    
6063    case 525:    case 525:
6064  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6065  #line 2598 "conf_parser.y"  #line 2544 "conf_parser.y"
6066      {      {
6067    ConfigFileEntry.disable_auth = yylval.number;    ConfigFileEntry.disable_auth = yylval.number;
6068  }  }
# Line 6129  yyreduce: Line 6070  yyreduce:
6070    
6071    case 526:    case 526:
6072  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6073  #line 2603 "conf_parser.y"  #line 2549 "conf_parser.y"
6074      {      {
6075    ConfigFileEntry.throttle_time = yylval.number;    ConfigFileEntry.throttle_time = yylval.number;
6076  }  }
# Line 6137  yyreduce: Line 6078  yyreduce:
6078    
6079    case 527:    case 527:
6080  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6081  #line 2608 "conf_parser.y"  #line 2554 "conf_parser.y"
6082      {      {
6083    ConfigFileEntry.oper_umodes = 0;    ConfigFileEntry.oper_umodes = 0;
6084  }  }
# Line 6145  yyreduce: Line 6086  yyreduce:
6086    
6087    case 531:    case 531:
6088  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6089  #line 2614 "conf_parser.y"  #line 2560 "conf_parser.y"
6090      {      {
6091    ConfigFileEntry.oper_umodes |= UMODE_BOTS;    ConfigFileEntry.oper_umodes |= UMODE_BOTS;
6092  }  }
# Line 6153  yyreduce: Line 6094  yyreduce:
6094    
6095    case 532:    case 532:
6096  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6097  #line 2617 "conf_parser.y"  #line 2563 "conf_parser.y"
6098      {      {
6099    ConfigFileEntry.oper_umodes |= UMODE_CCONN;    ConfigFileEntry.oper_umodes |= UMODE_CCONN;
6100  }  }
# Line 6161  yyreduce: Line 6102  yyreduce:
6102    
6103    case 533:    case 533:
6104  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6105  #line 2620 "conf_parser.y"  #line 2566 "conf_parser.y"
6106      {      {
6107    ConfigFileEntry.oper_umodes |= UMODE_CCONN_FULL;    ConfigFileEntry.oper_umodes |= UMODE_CCONN_FULL;
6108  }  }
# Line 6169  yyreduce: Line 6110  yyreduce:
6110    
6111    case 534:    case 534:
6112  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6113  #line 2623 "conf_parser.y"  #line 2569 "conf_parser.y"
6114      {      {
6115    ConfigFileEntry.oper_umodes |= UMODE_DEAF;    ConfigFileEntry.oper_umodes |= UMODE_DEAF;
6116  }  }
# Line 6177  yyreduce: Line 6118  yyreduce:
6118    
6119    case 535:    case 535:
6120  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6121  #line 2626 "conf_parser.y"  #line 2572 "conf_parser.y"
6122      {      {
6123    ConfigFileEntry.oper_umodes |= UMODE_DEBUG;    ConfigFileEntry.oper_umodes |= UMODE_DEBUG;
6124  }  }
# Line 6185  yyreduce: Line 6126  yyreduce:
6126    
6127    case 536:    case 536:
6128  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6129  #line 2629 "conf_parser.y"  #line 2575 "conf_parser.y"
6130      {      {
6131    ConfigFileEntry.oper_umodes |= UMODE_FULL;    ConfigFileEntry.oper_umodes |= UMODE_FULL;
6132  }  }
# Line 6193  yyreduce: Line 6134  yyreduce:
6134    
6135    case 537:    case 537:
6136  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6137  #line 2632 "conf_parser.y"  #line 2578 "conf_parser.y"
6138      {      {
6139    ConfigFileEntry.oper_umodes |= UMODE_HIDDEN;    ConfigFileEntry.oper_umodes |= UMODE_HIDDEN;
6140  }  }
# Line 6201  yyreduce: Line 6142  yyreduce:
6142    
6143    case 538:    case 538:
6144  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6145  #line 2635 "conf_parser.y"  #line 2581 "conf_parser.y"
6146      {      {
6147    ConfigFileEntry.oper_umodes |= UMODE_SKILL;    ConfigFileEntry.oper_umodes |= UMODE_SKILL;
6148  }  }
# Line 6209  yyreduce: Line 6150  yyreduce:
6150    
6151    case 539:    case 539:
6152  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6153  #line 2638 "conf_parser.y"  #line 2584 "conf_parser.y"
6154      {      {
6155    ConfigFileEntry.oper_umodes |= UMODE_NCHANGE;    ConfigFileEntry.oper_umodes |= UMODE_NCHANGE;
6156  }  }
# Line 6217  yyreduce: Line 6158  yyreduce:
6158    
6159    case 540:    case 540:
6160  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6161  #line 2641 "conf_parser.y"  #line 2587 "conf_parser.y"
6162      {      {
6163    ConfigFileEntry.oper_umodes |= UMODE_REJ;    ConfigFileEntry.oper_umodes |= UMODE_REJ;
6164  }  }
# Line 6225  yyreduce: Line 6166  yyreduce:
6166    
6167    case 541:    case 541:
6168  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6169  #line 2644 "conf_parser.y"  #line 2590 "conf_parser.y"
6170      {      {
6171    ConfigFileEntry.oper_umodes |= UMODE_UNAUTH;    ConfigFileEntry.oper_umodes |= UMODE_UNAUTH;
6172  }  }
# Line 6233  yyreduce: Line 6174  yyreduce:
6174    
6175    case 542:    case 542:
6176  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6177  #line 2647 "conf_parser.y"  #line 2593 "conf_parser.y"
6178      {      {
6179    ConfigFileEntry.oper_umodes |= UMODE_SPY;    ConfigFileEntry.oper_umodes |= UMODE_SPY;
6180  }  }
# Line 6241  yyreduce: Line 6182  yyreduce:
6182    
6183    case 543:    case 543:
6184  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6185  #line 2650 "conf_parser.y"  #line 2596 "conf_parser.y"
6186      {      {
6187    ConfigFileEntry.oper_umodes |= UMODE_EXTERNAL;    ConfigFileEntry.oper_umodes |= UMODE_EXTERNAL;
6188  }  }
# Line 6249  yyreduce: Line 6190  yyreduce:
6190    
6191    case 544:    case 544:
6192  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6193  #line 2653 "conf_parser.y"  #line 2599 "conf_parser.y"
6194      {      {
6195    ConfigFileEntry.oper_umodes |= UMODE_OPERWALL;    ConfigFileEntry.oper_umodes |= UMODE_OPERWALL;
6196  }  }
# Line 6257  yyreduce: Line 6198  yyreduce:
6198    
6199    case 545:    case 545:
6200  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6201  #line 2656 "conf_parser.y"  #line 2602 "conf_parser.y"
6202      {      {
6203    ConfigFileEntry.oper_umodes |= UMODE_SERVNOTICE;    ConfigFileEntry.oper_umodes |= UMODE_SERVNOTICE;
6204  }  }
# Line 6265  yyreduce: Line 6206  yyreduce:
6206    
6207    case 546:    case 546:
6208  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6209  #line 2659 "conf_parser.y"  #line 2605 "conf_parser.y"
6210      {      {
6211    ConfigFileEntry.oper_umodes |= UMODE_INVISIBLE;    ConfigFileEntry.oper_umodes |= UMODE_INVISIBLE;
6212  }  }
# Line 6273  yyreduce: Line 6214  yyreduce:
6214    
6215    case 547:    case 547:
6216  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6217  #line 2662 "conf_parser.y"  #line 2608 "conf_parser.y"
6218      {      {
6219    ConfigFileEntry.oper_umodes |= UMODE_WALLOP;    ConfigFileEntry.oper_umodes |= UMODE_WALLOP;
6220  }  }
# Line 6281  yyreduce: Line 6222  yyreduce:
6222    
6223    case 548:    case 548:
6224  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6225  #line 2665 "conf_parser.y"  #line 2611 "conf_parser.y"
6226      {      {
6227    ConfigFileEntry.oper_umodes |= UMODE_SOFTCALLERID;    ConfigFileEntry.oper_umodes |= UMODE_SOFTCALLERID;
6228  }  }
# Line 6289  yyreduce: Line 6230  yyreduce:
6230    
6231    case 549:    case 549:
6232  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6233  #line 2668 "conf_parser.y"  #line 2614 "conf_parser.y"
6234      {      {
6235    ConfigFileEntry.oper_umodes |= UMODE_CALLERID;    ConfigFileEntry.oper_umodes |= UMODE_CALLERID;
6236  }  }
# Line 6297  yyreduce: Line 6238  yyreduce:
6238    
6239    case 550:    case 550:
6240  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6241  #line 2671 "conf_parser.y"  #line 2617 "conf_parser.y"
6242      {      {
6243    ConfigFileEntry.oper_umodes |= UMODE_LOCOPS;    ConfigFileEntry.oper_umodes |= UMODE_LOCOPS;
6244  }  }
# Line 6305  yyreduce: Line 6246  yyreduce:
6246    
6247    case 551:    case 551:
6248  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6249  #line 2676 "conf_parser.y"  #line 2622 "conf_parser.y"
6250      {      {
6251    ConfigFileEntry.oper_only_umodes = 0;    ConfigFileEntry.oper_only_umodes = 0;
6252  }  }
# Line 6313  yyreduce: Line 6254  yyreduce:
6254    
6255    case 555:    case 555:
6256  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6257  #line 2682 "conf_parser.y"  #line 2628 "conf_parser.y"
6258      {      {
6259    ConfigFileEntry.oper_only_umodes |= UMODE_BOTS;    ConfigFileEntry.oper_only_umodes |= UMODE_BOTS;
6260  }  }
# Line 6321  yyreduce: Line 6262  yyreduce:
6262    
6263    case 556:    case 556:
6264  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6265  #line 2685 "conf_parser.y"  #line 2631 "conf_parser.y"
6266      {      {
6267    ConfigFileEntry.oper_only_umodes |= UMODE_CCONN;    ConfigFileEntry.oper_only_umodes |= UMODE_CCONN;
6268  }  }
# Line 6329  yyreduce: Line 6270  yyreduce:
6270    
6271    case 557:    case 557:
6272  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6273  #line 2688 "conf_parser.y"  #line 2634 "conf_parser.y"
6274      {      {
6275    ConfigFileEntry.oper_only_umodes |= UMODE_CCONN_FULL;    ConfigFileEntry.oper_only_umodes |= UMODE_CCONN_FULL;
6276  }  }
# Line 6337  yyreduce: Line 6278  yyreduce:
6278    
6279    case 558:    case 558:
6280  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6281  #line 2691 "conf_parser.y"  #line 2637 "conf_parser.y"
6282      {      {
6283    ConfigFileEntry.oper_only_umodes |= UMODE_DEAF;    ConfigFileEntry.oper_only_umodes |= UMODE_DEAF;
6284  }  }
# Line 6345  yyreduce: Line 6286  yyreduce:
6286    
6287    case 559:    case 559:
6288  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6289  #line 2694 "conf_parser.y"  #line 2640 "conf_parser.y"
6290      {      {
6291    ConfigFileEntry.oper_only_umodes |= UMODE_DEBUG;    ConfigFileEntry.oper_only_umodes |= UMODE_DEBUG;
6292  }  }
# Line 6353  yyreduce: Line 6294  yyreduce:
6294    
6295    case 560:    case 560:
6296  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6297  #line 2697 "conf_parser.y"  #line 2643 "conf_parser.y"
6298      {      {
6299    ConfigFileEntry.oper_only_umodes |= UMODE_FULL;    ConfigFileEntry.oper_only_umodes |= UMODE_FULL;
6300  }  }
# Line 6361  yyreduce: Line 6302  yyreduce:
6302    
6303    case 561:    case 561:
6304  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6305  #line 2700 "conf_parser.y"  #line 2646 "conf_parser.y"
6306      {      {
6307    ConfigFileEntry.oper_only_umodes |= UMODE_SKILL;    ConfigFileEntry.oper_only_umodes |= UMODE_SKILL;
6308  }  }
# Line 6369  yyreduce: Line 6310  yyreduce:
6310    
6311    case 562:    case 562:
6312  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6313  #line 2703 "conf_parser.y"  #line 2649 "conf_parser.y"
6314      {      {
6315    ConfigFileEntry.oper_only_umodes |= UMODE_HIDDEN;    ConfigFileEntry.oper_only_umodes |= UMODE_HIDDEN;
6316  }  }
# Line 6377  yyreduce: Line 6318  yyreduce:
6318    
6319    case 563:    case 563:
6320  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6321  #line 2706 "conf_parser.y"  #line 2652 "conf_parser.y"
6322      {      {
6323    ConfigFileEntry.oper_only_umodes |= UMODE_NCHANGE;    ConfigFileEntry.oper_only_umodes |= UMODE_NCHANGE;
6324  }  }
# Line 6385  yyreduce: Line 6326  yyreduce:
6326    
6327    case 564:    case 564:
6328  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6329  #line 2709 "conf_parser.y"  #line 2655 "conf_parser.y"
6330      {      {
6331    ConfigFileEntry.oper_only_umodes |= UMODE_REJ;    ConfigFileEntry.oper_only_umodes |= UMODE_REJ;
6332  }  }
# Line 6393  yyreduce: Line 6334  yyreduce:
6334    
6335    case 565:    case 565:
6336  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6337  #line 2712 "conf_parser.y"  #line 2658 "conf_parser.y"
6338      {      {
6339    ConfigFileEntry.oper_only_umodes |= UMODE_UNAUTH;    ConfigFileEntry.oper_only_umodes |= UMODE_UNAUTH;
6340  }  }
# Line 6401  yyreduce: Line 6342  yyreduce:
6342    
6343    case 566:    case 566:
6344  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6345  #line 2715 "conf_parser.y"  #line 2661 "conf_parser.y"
6346      {      {
6347    ConfigFileEntry.oper_only_umodes |= UMODE_SPY;    ConfigFileEntry.oper_only_umodes |= UMODE_SPY;
6348  }  }
# Line 6409  yyreduce: Line 6350  yyreduce:
6350    
6351    case 567:    case 567:
6352  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6353  #line 2718 "conf_parser.y"  #line 2664 "conf_parser.y"
6354      {      {
6355    ConfigFileEntry.oper_only_umodes |= UMODE_EXTERNAL;    ConfigFileEntry.oper_only_umodes |= UMODE_EXTERNAL;
6356  }  }
# Line 6417  yyreduce: Line 6358  yyreduce:
6358    
6359    case 568:    case 568:
6360  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6361  #line 2721 "conf_parser.y"  #line 2667 "conf_parser.y"
6362      {      {
6363    ConfigFileEntry.oper_only_umodes |= UMODE_OPERWALL;    ConfigFileEntry.oper_only_umodes |= UMODE_OPERWALL;
6364  }  }
# Line 6425  yyreduce: Line 6366  yyreduce:
6366    
6367    case 569:    case 569:
6368  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6369  #line 2724 "conf_parser.y"  #line 2670 "conf_parser.y"
6370      {      {
6371    ConfigFileEntry.oper_only_umodes |= UMODE_SERVNOTICE;    ConfigFileEntry.oper_only_umodes |= UMODE_SERVNOTICE;
6372  }  }
# Line 6433  yyreduce: Line 6374  yyreduce:
6374    
6375    case 570:    case 570:
6376  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6377  #line 2727 "conf_parser.y"  #line 2673 "conf_parser.y"
6378      {      {
6379    ConfigFileEntry.oper_only_umodes |= UMODE_INVISIBLE;    ConfigFileEntry.oper_only_umodes |= UMODE_INVISIBLE;
6380  }  }
# Line 6441  yyreduce: Line 6382  yyreduce:
6382    
6383    case 571:    case 571:
6384  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6385  #line 2730 "conf_parser.y"  #line 2676 "conf_parser.y"
6386      {      {
6387    ConfigFileEntry.oper_only_umodes |= UMODE_WALLOP;    ConfigFileEntry.oper_only_umodes |= UMODE_WALLOP;
6388  }  }
# Line 6449  yyreduce: Line 6390  yyreduce:
6390    
6391    case 572:    case 572:
6392  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6393  #line 2733 "conf_parser.y"  #line 2679 "conf_parser.y"
6394      {      {
6395    ConfigFileEntry.oper_only_umodes |= UMODE_SOFTCALLERID;    ConfigFileEntry.oper_only_umodes |= UMODE_SOFTCALLERID;
6396  }  }
# Line 6457  yyreduce: Line 6398  yyreduce:
6398    
6399    case 573:    case 573:
6400  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6401  #line 2736 "conf_parser.y"  #line 2682 "conf_parser.y"
6402      {      {
6403    ConfigFileEntry.oper_only_umodes |= UMODE_CALLERID;    ConfigFileEntry.oper_only_umodes |= UMODE_CALLERID;
6404  }  }
# Line 6465  yyreduce: Line 6406  yyreduce:
6406    
6407    case 574:    case 574:
6408  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6409  #line 2739 "conf_parser.y"  #line 2685 "conf_parser.y"
6410      {      {
6411    ConfigFileEntry.oper_only_umodes |= UMODE_LOCOPS;    ConfigFileEntry.oper_only_umodes |= UMODE_LOCOPS;
6412  }  }
# Line 6473  yyreduce: Line 6414  yyreduce:
6414    
6415    case 575:    case 575:
6416  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6417  #line 2744 "conf_parser.y"  #line 2690 "conf_parser.y"
6418      {      {
6419    ConfigFileEntry.min_nonwildcard = (yyvsp[(3) - (4)].number);    ConfigFileEntry.min_nonwildcard = (yyvsp[(3) - (4)].number);
6420  }  }
# Line 6481  yyreduce: Line 6422  yyreduce:
6422    
6423    case 576:    case 576:
6424  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6425  #line 2749 "conf_parser.y"  #line 2695 "conf_parser.y"
6426      {      {
6427    ConfigFileEntry.min_nonwildcard_simple = (yyvsp[(3) - (4)].number);    ConfigFileEntry.min_nonwildcard_simple = (yyvsp[(3) - (4)].number);
6428  }  }
# Line 6489  yyreduce: Line 6430  yyreduce:
6430    
6431    case 577:    case 577:
6432  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6433  #line 2754 "conf_parser.y"  #line 2700 "conf_parser.y"
6434      {      {
6435    ConfigFileEntry.default_floodcount = (yyvsp[(3) - (4)].number);    ConfigFileEntry.default_floodcount = (yyvsp[(3) - (4)].number);
6436  }  }
# Line 6497  yyreduce: Line 6438  yyreduce:
6438    
6439    case 596:    case 596:
6440  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6441  #line 2777 "conf_parser.y"  #line 2723 "conf_parser.y"
6442      {      {
6443    ConfigChannel.disable_fake_channels = yylval.number;    ConfigChannel.disable_fake_channels = yylval.number;
6444  }  }
# Line 6505  yyreduce: Line 6446  yyreduce:
6446    
6447    case 597:    case 597:
6448  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6449  #line 2782 "conf_parser.y"  #line 2728 "conf_parser.y"
6450      {      {
6451    ConfigChannel.restrict_channels = yylval.number;    ConfigChannel.restrict_channels = yylval.number;
6452  }  }
# Line 6513  yyreduce: Line 6454  yyreduce:
6454    
6455    case 598:    case 598:
6456  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6457  #line 2787 "conf_parser.y"  #line 2733 "conf_parser.y"
6458      {      {
6459    ConfigChannel.knock_delay = (yyvsp[(3) - (4)].number);    ConfigChannel.knock_delay = (yyvsp[(3) - (4)].number);
6460  }  }
# Line 6521  yyreduce: Line 6462  yyreduce:
6462    
6463    case 599:    case 599:
6464  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6465  #line 2792 "conf_parser.y"  #line 2738 "conf_parser.y"
6466      {      {
6467    ConfigChannel.knock_delay_channel = (yyvsp[(3) - (4)].number);    ConfigChannel.knock_delay_channel = (yyvsp[(3) - (4)].number);
6468  }  }
# Line 6529  yyreduce: Line 6470  yyreduce:
6470    
6471    case 600:    case 600:
6472  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6473  #line 2797 "conf_parser.y"  #line 2743 "conf_parser.y"
6474      {      {
6475    ConfigChannel.max_chans_per_user = (yyvsp[(3) - (4)].number);    ConfigChannel.max_chans_per_user = (yyvsp[(3) - (4)].number);
6476  }  }
# Line 6537  yyreduce: Line 6478  yyreduce:
6478    
6479    case 601:    case 601:
6480  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6481  #line 2802 "conf_parser.y"  #line 2748 "conf_parser.y"
6482      {      {
6483    ConfigChannel.max_chans_per_oper = (yyvsp[(3) - (4)].number);    ConfigChannel.max_chans_per_oper = (yyvsp[(3) - (4)].number);
6484  }  }
# Line 6545  yyreduce: Line 6486  yyreduce:
6486    
6487    case 602:    case 602:
6488  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6489  #line 2807 "conf_parser.y"  #line 2753 "conf_parser.y"
6490      {      {
6491    ConfigChannel.quiet_on_ban = yylval.number;    ConfigChannel.quiet_on_ban = yylval.number;
6492  }  }
# Line 6553  yyreduce: Line 6494  yyreduce:
6494    
6495    case 603:    case 603:
6496  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6497  #line 2812 "conf_parser.y"  #line 2758 "conf_parser.y"
6498      {      {
6499    ConfigChannel.max_bans = (yyvsp[(3) - (4)].number);    ConfigChannel.max_bans = (yyvsp[(3) - (4)].number);
6500  }  }
# Line 6561  yyreduce: Line 6502  yyreduce:
6502    
6503    case 604:    case 604:
6504  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6505  #line 2817 "conf_parser.y"  #line 2763 "conf_parser.y"
6506      {      {
6507    ConfigChannel.default_split_user_count = (yyvsp[(3) - (4)].number);    ConfigChannel.default_split_user_count = (yyvsp[(3) - (4)].number);
6508  }  }
# Line 6569  yyreduce: Line 6510  yyreduce:
6510    
6511    case 605:    case 605:
6512  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6513  #line 2822 "conf_parser.y"  #line 2768 "conf_parser.y"
6514      {      {
6515    ConfigChannel.default_split_server_count = (yyvsp[(3) - (4)].number);    ConfigChannel.default_split_server_count = (yyvsp[(3) - (4)].number);
6516  }  }
# Line 6577  yyreduce: Line 6518  yyreduce:
6518    
6519    case 606:    case 606:
6520  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6521  #line 2827 "conf_parser.y"  #line 2773 "conf_parser.y"
6522      {      {
6523    ConfigChannel.no_create_on_split = yylval.number;    ConfigChannel.no_create_on_split = yylval.number;
6524  }  }
# Line 6585  yyreduce: Line 6526  yyreduce:
6526    
6527    case 607:    case 607:
6528  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6529  #line 2832 "conf_parser.y"  #line 2778 "conf_parser.y"
6530      {      {
6531    ConfigChannel.no_join_on_split = yylval.number;    ConfigChannel.no_join_on_split = yylval.number;
6532  }  }
# Line 6593  yyreduce: Line 6534  yyreduce:
6534    
6535    case 608:    case 608:
6536  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6537  #line 2837 "conf_parser.y"  #line 2783 "conf_parser.y"
6538      {      {
6539    GlobalSetOptions.joinfloodcount = yylval.number;    GlobalSetOptions.joinfloodcount = yylval.number;
6540  }  }
# Line 6601  yyreduce: Line 6542  yyreduce:
6542    
6543    case 609:    case 609:
6544  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6545  #line 2842 "conf_parser.y"  #line 2788 "conf_parser.y"
6546      {      {
6547    GlobalSetOptions.joinfloodtime = yylval.number;    GlobalSetOptions.joinfloodtime = yylval.number;
6548  }  }
# Line 6609  yyreduce: Line 6550  yyreduce:
6550    
6551    case 620:    case 620:
6552  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6553  #line 2860 "conf_parser.y"  #line 2806 "conf_parser.y"
6554      {      {
6555    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
6556      ConfigServerHide.flatten_links = yylval.number;      ConfigServerHide.flatten_links = yylval.number;
# Line 6618  yyreduce: Line 6559  yyreduce:
6559    
6560    case 621:    case 621:
6561  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6562  #line 2866 "conf_parser.y"  #line 2812 "conf_parser.y"
6563      {      {
6564    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
6565      ConfigServerHide.hide_servers = yylval.number;      ConfigServerHide.hide_servers = yylval.number;
# Line 6627  yyreduce: Line 6568  yyreduce:
6568    
6569    case 622:    case 622:
6570  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6571  #line 2872 "conf_parser.y"  #line 2818 "conf_parser.y"
6572      {      {
6573    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
6574    {    {
# Line 6639  yyreduce: Line 6580  yyreduce:
6580    
6581    case 623:    case 623:
6582  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6583  #line 2881 "conf_parser.y"  #line 2827 "conf_parser.y"
6584      {      {
6585    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
6586    {    {
# Line 6656  yyreduce: Line 6597  yyreduce:
6597    
6598    case 624:    case 624:
6599  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6600  #line 2895 "conf_parser.y"  #line 2841 "conf_parser.y"
6601      {      {
6602    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
6603      ConfigServerHide.hidden = yylval.number;      ConfigServerHide.hidden = yylval.number;
# Line 6665  yyreduce: Line 6606  yyreduce:
6606    
6607    case 625:    case 625:
6608  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6609  #line 2901 "conf_parser.y"  #line 2847 "conf_parser.y"
6610      {      {
6611    if (conf_parser_ctx.pass == 2)    if (conf_parser_ctx.pass == 2)
6612      ConfigServerHide.hide_server_ips = yylval.number;      ConfigServerHide.hide_server_ips = yylval.number;
# Line 6674  yyreduce: Line 6615  yyreduce:
6615    
6616    
6617  /* Line 1813 of yacc.c  */  /* Line 1813 of yacc.c  */
6618  #line 6678 "conf_parser.c"  #line 6619 "conf_parser.c"
6619        default: break;        default: break;
6620      }      }
6621    /* User semantic actions sometimes alter yychar, and that requires    /* User semantic actions sometimes alter yychar, and that requires

Legend:
Removed from v.1646  
changed lines
  Added in v.1647

svnadmin@ircd-hybrid.org
ViewVC Help
Powered by ViewVC 1.1.28