| 1 |
/* A Bison parser, made by GNU Bison 3.0.2. */ |
| 2 |
|
| 3 |
/* Bison implementation for Yacc-like parsers in C |
| 4 |
|
| 5 |
Copyright (C) 1984, 1989-1990, 2000-2013 Free Software Foundation, Inc. |
| 6 |
|
| 7 |
This program is free software: you can redistribute it and/or modify |
| 8 |
it under the terms of the GNU General Public License as published by |
| 9 |
the Free Software Foundation, either version 3 of the License, or |
| 10 |
(at your option) any later version. |
| 11 |
|
| 12 |
This program is distributed in the hope that it will be useful, |
| 13 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 14 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 15 |
GNU General Public License for more details. |
| 16 |
|
| 17 |
You should have received a copy of the GNU General Public License |
| 18 |
along with this program. If not, see <http://www.gnu.org/licenses/>. */ |
| 19 |
|
| 20 |
/* As a special exception, you may create a larger work that contains |
| 21 |
part or all of the Bison parser skeleton and distribute that work |
| 22 |
under terms of your choice, so long as that work isn't itself a |
| 23 |
parser generator using the skeleton or a modified version thereof |
| 24 |
as a parser skeleton. Alternatively, if you modify or redistribute |
| 25 |
the parser skeleton itself, you may (at your option) remove this |
| 26 |
special exception, which will cause the skeleton and the resulting |
| 27 |
Bison output files to be licensed under the GNU General Public |
| 28 |
License without this special exception. |
| 29 |
|
| 30 |
This special exception was added by the Free Software Foundation in |
| 31 |
version 2.2 of Bison. */ |
| 32 |
|
| 33 |
/* C LALR(1) parser skeleton written by Richard Stallman, by |
| 34 |
simplifying the original so-called "semantic" parser. */ |
| 35 |
|
| 36 |
/* All symbols defined below should begin with yy or YY, to avoid |
| 37 |
infringing on user name space. This should be done even for local |
| 38 |
variables, as they might otherwise be expanded by user macros. |
| 39 |
There are some unavoidable exceptions within include files to |
| 40 |
define necessary library symbols; they are noted "INFRINGES ON |
| 41 |
USER NAME SPACE" below. */ |
| 42 |
|
| 43 |
/* Identify Bison output. */ |
| 44 |
#define YYBISON 1 |
| 45 |
|
| 46 |
/* Bison version. */ |
| 47 |
#define YYBISON_VERSION "3.0.2" |
| 48 |
|
| 49 |
/* Skeleton name. */ |
| 50 |
#define YYSKELETON_NAME "yacc.c" |
| 51 |
|
| 52 |
/* Pure parsers. */ |
| 53 |
#define YYPURE 0 |
| 54 |
|
| 55 |
/* Push parsers. */ |
| 56 |
#define YYPUSH 0 |
| 57 |
|
| 58 |
/* Pull parsers. */ |
| 59 |
#define YYPULL 1 |
| 60 |
|
| 61 |
|
| 62 |
|
| 63 |
|
| 64 |
/* Copy the first part of user declarations. */ |
| 65 |
#line 25 "config-parser.y" /* yacc.c:339 */ |
| 66 |
|
| 67 |
#include <stdio.h> |
| 68 |
#include <string.h> |
| 69 |
#include "malloc.h" |
| 70 |
#include "config.h" |
| 71 |
|
| 72 |
int yylex(void); |
| 73 |
|
| 74 |
int yydebug=0; |
| 75 |
void *tmp; /* Variable to temporarily hold nodes before insertion to list */ |
| 76 |
|
| 77 |
|
| 78 |
#line 79 "config-parser.c" /* yacc.c:339 */ |
| 79 |
|
| 80 |
# ifndef YY_NULLPTR |
| 81 |
# if defined __cplusplus && 201103L <= __cplusplus |
| 82 |
# define YY_NULLPTR nullptr |
| 83 |
# else |
| 84 |
# define YY_NULLPTR 0 |
| 85 |
# endif |
| 86 |
# endif |
| 87 |
|
| 88 |
/* Enabling verbose error messages. */ |
| 89 |
#ifdef YYERROR_VERBOSE |
| 90 |
# undef YYERROR_VERBOSE |
| 91 |
# define YYERROR_VERBOSE 1 |
| 92 |
#else |
| 93 |
# define YYERROR_VERBOSE 0 |
| 94 |
#endif |
| 95 |
|
| 96 |
/* In a future release of Bison, this section will be replaced |
| 97 |
by #include "y.tab.h". */ |
| 98 |
#ifndef YY_YY_CONFIG_PARSER_H_INCLUDED |
| 99 |
# define YY_YY_CONFIG_PARSER_H_INCLUDED |
| 100 |
/* Debug traces. */ |
| 101 |
#ifndef YYDEBUG |
| 102 |
# define YYDEBUG 0 |
| 103 |
#endif |
| 104 |
#if YYDEBUG |
| 105 |
extern int yydebug; |
| 106 |
#endif |
| 107 |
|
| 108 |
/* Token type. */ |
| 109 |
#ifndef YYTOKENTYPE |
| 110 |
# define YYTOKENTYPE |
| 111 |
enum yytokentype |
| 112 |
{ |
| 113 |
AWAY = 258, |
| 114 |
BAN_UNKNOWN = 259, |
| 115 |
BLACKLIST = 260, |
| 116 |
BYTES = 261, |
| 117 |
KBYTES = 262, |
| 118 |
MBYTES = 263, |
| 119 |
CHANNEL = 264, |
| 120 |
CONNREGEX = 265, |
| 121 |
DNS_FDLIMIT = 266, |
| 122 |
DNSBL_FROM = 267, |
| 123 |
DNSBL_TO = 268, |
| 124 |
EXEMPT = 269, |
| 125 |
FD = 270, |
| 126 |
INVITE = 271, |
| 127 |
IRC = 272, |
| 128 |
KLINE = 273, |
| 129 |
KEY = 274, |
| 130 |
MASK = 275, |
| 131 |
MAX_READ = 276, |
| 132 |
MODE = 277, |
| 133 |
NAME = 278, |
| 134 |
NEGCACHE = 279, |
| 135 |
NICK = 280, |
| 136 |
NICKSERV = 281, |
| 137 |
OPER = 282, |
| 138 |
OPM = 283, |
| 139 |
OPTIONS = 284, |
| 140 |
PASSWORD = 285, |
| 141 |
PERFORM = 286, |
| 142 |
PIDFILE = 287, |
| 143 |
PORT = 288, |
| 144 |
PROTOCOL = 289, |
| 145 |
REALNAME = 290, |
| 146 |
REPLY = 291, |
| 147 |
SCANLOG = 292, |
| 148 |
SCANNER = 293, |
| 149 |
SECONDS = 294, |
| 150 |
MINUTES = 295, |
| 151 |
HOURS = 296, |
| 152 |
DAYS = 297, |
| 153 |
WEEKS = 298, |
| 154 |
MONTHS = 299, |
| 155 |
YEARS = 300, |
| 156 |
SENDMAIL = 301, |
| 157 |
SERVER = 302, |
| 158 |
TARGET_IP = 303, |
| 159 |
TARGET_PORT = 304, |
| 160 |
TARGET_STRING = 305, |
| 161 |
TIMEOUT = 306, |
| 162 |
TYPE = 307, |
| 163 |
USERNAME = 308, |
| 164 |
USER = 309, |
| 165 |
VHOST = 310, |
| 166 |
NUMBER = 311, |
| 167 |
STRING = 312, |
| 168 |
PROTOCOLTYPE = 313 |
| 169 |
}; |
| 170 |
#endif |
| 171 |
/* Tokens. */ |
| 172 |
#define AWAY 258 |
| 173 |
#define BAN_UNKNOWN 259 |
| 174 |
#define BLACKLIST 260 |
| 175 |
#define BYTES 261 |
| 176 |
#define KBYTES 262 |
| 177 |
#define MBYTES 263 |
| 178 |
#define CHANNEL 264 |
| 179 |
#define CONNREGEX 265 |
| 180 |
#define DNS_FDLIMIT 266 |
| 181 |
#define DNSBL_FROM 267 |
| 182 |
#define DNSBL_TO 268 |
| 183 |
#define EXEMPT 269 |
| 184 |
#define FD 270 |
| 185 |
#define INVITE 271 |
| 186 |
#define IRC 272 |
| 187 |
#define KLINE 273 |
| 188 |
#define KEY 274 |
| 189 |
#define MASK 275 |
| 190 |
#define MAX_READ 276 |
| 191 |
#define MODE 277 |
| 192 |
#define NAME 278 |
| 193 |
#define NEGCACHE 279 |
| 194 |
#define NICK 280 |
| 195 |
#define NICKSERV 281 |
| 196 |
#define OPER 282 |
| 197 |
#define OPM 283 |
| 198 |
#define OPTIONS 284 |
| 199 |
#define PASSWORD 285 |
| 200 |
#define PERFORM 286 |
| 201 |
#define PIDFILE 287 |
| 202 |
#define PORT 288 |
| 203 |
#define PROTOCOL 289 |
| 204 |
#define REALNAME 290 |
| 205 |
#define REPLY 291 |
| 206 |
#define SCANLOG 292 |
| 207 |
#define SCANNER 293 |
| 208 |
#define SECONDS 294 |
| 209 |
#define MINUTES 295 |
| 210 |
#define HOURS 296 |
| 211 |
#define DAYS 297 |
| 212 |
#define WEEKS 298 |
| 213 |
#define MONTHS 299 |
| 214 |
#define YEARS 300 |
| 215 |
#define SENDMAIL 301 |
| 216 |
#define SERVER 302 |
| 217 |
#define TARGET_IP 303 |
| 218 |
#define TARGET_PORT 304 |
| 219 |
#define TARGET_STRING 305 |
| 220 |
#define TIMEOUT 306 |
| 221 |
#define TYPE 307 |
| 222 |
#define USERNAME 308 |
| 223 |
#define USER 309 |
| 224 |
#define VHOST 310 |
| 225 |
#define NUMBER 311 |
| 226 |
#define STRING 312 |
| 227 |
#define PROTOCOLTYPE 313 |
| 228 |
|
| 229 |
/* Value type. */ |
| 230 |
#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED |
| 231 |
typedef union YYSTYPE YYSTYPE; |
| 232 |
union YYSTYPE |
| 233 |
{ |
| 234 |
#line 85 "config-parser.y" /* yacc.c:355 */ |
| 235 |
|
| 236 |
int number; |
| 237 |
char *string; |
| 238 |
|
| 239 |
#line 240 "config-parser.c" /* yacc.c:355 */ |
| 240 |
}; |
| 241 |
# define YYSTYPE_IS_TRIVIAL 1 |
| 242 |
# define YYSTYPE_IS_DECLARED 1 |
| 243 |
#endif |
| 244 |
|
| 245 |
|
| 246 |
extern YYSTYPE yylval; |
| 247 |
|
| 248 |
int yyparse (void); |
| 249 |
|
| 250 |
#endif /* !YY_YY_CONFIG_PARSER_H_INCLUDED */ |
| 251 |
|
| 252 |
/* Copy the second part of user declarations. */ |
| 253 |
|
| 254 |
#line 255 "config-parser.c" /* yacc.c:358 */ |
| 255 |
|
| 256 |
#ifdef short |
| 257 |
# undef short |
| 258 |
#endif |
| 259 |
|
| 260 |
#ifdef YYTYPE_UINT8 |
| 261 |
typedef YYTYPE_UINT8 yytype_uint8; |
| 262 |
#else |
| 263 |
typedef unsigned char yytype_uint8; |
| 264 |
#endif |
| 265 |
|
| 266 |
#ifdef YYTYPE_INT8 |
| 267 |
typedef YYTYPE_INT8 yytype_int8; |
| 268 |
#else |
| 269 |
typedef signed char yytype_int8; |
| 270 |
#endif |
| 271 |
|
| 272 |
#ifdef YYTYPE_UINT16 |
| 273 |
typedef YYTYPE_UINT16 yytype_uint16; |
| 274 |
#else |
| 275 |
typedef unsigned short int yytype_uint16; |
| 276 |
#endif |
| 277 |
|
| 278 |
#ifdef YYTYPE_INT16 |
| 279 |
typedef YYTYPE_INT16 yytype_int16; |
| 280 |
#else |
| 281 |
typedef short int yytype_int16; |
| 282 |
#endif |
| 283 |
|
| 284 |
#ifndef YYSIZE_T |
| 285 |
# ifdef __SIZE_TYPE__ |
| 286 |
# define YYSIZE_T __SIZE_TYPE__ |
| 287 |
# elif defined size_t |
| 288 |
# define YYSIZE_T size_t |
| 289 |
# elif ! defined YYSIZE_T |
| 290 |
# include <stddef.h> /* INFRINGES ON USER NAME SPACE */ |
| 291 |
# define YYSIZE_T size_t |
| 292 |
# else |
| 293 |
# define YYSIZE_T unsigned int |
| 294 |
# endif |
| 295 |
#endif |
| 296 |
|
| 297 |
#define YYSIZE_MAXIMUM ((YYSIZE_T) -1) |
| 298 |
|
| 299 |
#ifndef YY_ |
| 300 |
# if defined YYENABLE_NLS && YYENABLE_NLS |
| 301 |
# if ENABLE_NLS |
| 302 |
# include <libintl.h> /* INFRINGES ON USER NAME SPACE */ |
| 303 |
# define YY_(Msgid) dgettext ("bison-runtime", Msgid) |
| 304 |
# endif |
| 305 |
# endif |
| 306 |
# ifndef YY_ |
| 307 |
# define YY_(Msgid) Msgid |
| 308 |
# endif |
| 309 |
#endif |
| 310 |
|
| 311 |
#ifndef YY_ATTRIBUTE |
| 312 |
# if (defined __GNUC__ \ |
| 313 |
&& (2 < __GNUC__ || (__GNUC__ == 2 && 96 <= __GNUC_MINOR__))) \ |
| 314 |
|| defined __SUNPRO_C && 0x5110 <= __SUNPRO_C |
| 315 |
# define YY_ATTRIBUTE(Spec) __attribute__(Spec) |
| 316 |
# else |
| 317 |
# define YY_ATTRIBUTE(Spec) /* empty */ |
| 318 |
# endif |
| 319 |
#endif |
| 320 |
|
| 321 |
#ifndef YY_ATTRIBUTE_PURE |
| 322 |
# define YY_ATTRIBUTE_PURE YY_ATTRIBUTE ((__pure__)) |
| 323 |
#endif |
| 324 |
|
| 325 |
#ifndef YY_ATTRIBUTE_UNUSED |
| 326 |
# define YY_ATTRIBUTE_UNUSED YY_ATTRIBUTE ((__unused__)) |
| 327 |
#endif |
| 328 |
|
| 329 |
#if !defined _Noreturn \ |
| 330 |
&& (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112) |
| 331 |
# if defined _MSC_VER && 1200 <= _MSC_VER |
| 332 |
# define _Noreturn __declspec (noreturn) |
| 333 |
# else |
| 334 |
# define _Noreturn YY_ATTRIBUTE ((__noreturn__)) |
| 335 |
# endif |
| 336 |
#endif |
| 337 |
|
| 338 |
/* Suppress unused-variable warnings by "using" E. */ |
| 339 |
#if ! defined lint || defined __GNUC__ |
| 340 |
# define YYUSE(E) ((void) (E)) |
| 341 |
#else |
| 342 |
# define YYUSE(E) /* empty */ |
| 343 |
#endif |
| 344 |
|
| 345 |
#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__ |
| 346 |
/* Suppress an incorrect diagnostic about yylval being uninitialized. */ |
| 347 |
# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \ |
| 348 |
_Pragma ("GCC diagnostic push") \ |
| 349 |
_Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\ |
| 350 |
_Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"") |
| 351 |
# define YY_IGNORE_MAYBE_UNINITIALIZED_END \ |
| 352 |
_Pragma ("GCC diagnostic pop") |
| 353 |
#else |
| 354 |
# define YY_INITIAL_VALUE(Value) Value |
| 355 |
#endif |
| 356 |
#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN |
| 357 |
# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN |
| 358 |
# define YY_IGNORE_MAYBE_UNINITIALIZED_END |
| 359 |
#endif |
| 360 |
#ifndef YY_INITIAL_VALUE |
| 361 |
# define YY_INITIAL_VALUE(Value) /* Nothing. */ |
| 362 |
#endif |
| 363 |
|
| 364 |
|
| 365 |
#if ! defined yyoverflow || YYERROR_VERBOSE |
| 366 |
|
| 367 |
/* The parser invokes alloca or malloc; define the necessary symbols. */ |
| 368 |
|
| 369 |
# ifdef YYSTACK_USE_ALLOCA |
| 370 |
# if YYSTACK_USE_ALLOCA |
| 371 |
# ifdef __GNUC__ |
| 372 |
# define YYSTACK_ALLOC __builtin_alloca |
| 373 |
# elif defined __BUILTIN_VA_ARG_INCR |
| 374 |
# include <alloca.h> /* INFRINGES ON USER NAME SPACE */ |
| 375 |
# elif defined _AIX |
| 376 |
# define YYSTACK_ALLOC __alloca |
| 377 |
# elif defined _MSC_VER |
| 378 |
# include <malloc.h> /* INFRINGES ON USER NAME SPACE */ |
| 379 |
# define alloca _alloca |
| 380 |
# else |
| 381 |
# define YYSTACK_ALLOC alloca |
| 382 |
# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS |
| 383 |
# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */ |
| 384 |
/* Use EXIT_SUCCESS as a witness for stdlib.h. */ |
| 385 |
# ifndef EXIT_SUCCESS |
| 386 |
# define EXIT_SUCCESS 0 |
| 387 |
# endif |
| 388 |
# endif |
| 389 |
# endif |
| 390 |
# endif |
| 391 |
# endif |
| 392 |
|
| 393 |
# ifdef YYSTACK_ALLOC |
| 394 |
/* Pacify GCC's 'empty if-body' warning. */ |
| 395 |
# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0) |
| 396 |
# ifndef YYSTACK_ALLOC_MAXIMUM |
| 397 |
/* The OS might guarantee only one guard page at the bottom of the stack, |
| 398 |
and a page size can be as small as 4096 bytes. So we cannot safely |
| 399 |
invoke alloca (N) if N exceeds 4096. Use a slightly smaller number |
| 400 |
to allow for a few compiler-allocated temporary stack slots. */ |
| 401 |
# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ |
| 402 |
# endif |
| 403 |
# else |
| 404 |
# define YYSTACK_ALLOC YYMALLOC |
| 405 |
# define YYSTACK_FREE YYFREE |
| 406 |
# ifndef YYSTACK_ALLOC_MAXIMUM |
| 407 |
# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM |
| 408 |
# endif |
| 409 |
# if (defined __cplusplus && ! defined EXIT_SUCCESS \ |
| 410 |
&& ! ((defined YYMALLOC || defined malloc) \ |
| 411 |
&& (defined YYFREE || defined free))) |
| 412 |
# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */ |
| 413 |
# ifndef EXIT_SUCCESS |
| 414 |
# define EXIT_SUCCESS 0 |
| 415 |
# endif |
| 416 |
# endif |
| 417 |
# ifndef YYMALLOC |
| 418 |
# define YYMALLOC malloc |
| 419 |
# if ! defined malloc && ! defined EXIT_SUCCESS |
| 420 |
void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ |
| 421 |
# endif |
| 422 |
# endif |
| 423 |
# ifndef YYFREE |
| 424 |
# define YYFREE free |
| 425 |
# if ! defined free && ! defined EXIT_SUCCESS |
| 426 |
void free (void *); /* INFRINGES ON USER NAME SPACE */ |
| 427 |
# endif |
| 428 |
# endif |
| 429 |
# endif |
| 430 |
#endif /* ! defined yyoverflow || YYERROR_VERBOSE */ |
| 431 |
|
| 432 |
|
| 433 |
#if (! defined yyoverflow \ |
| 434 |
&& (! defined __cplusplus \ |
| 435 |
|| (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) |
| 436 |
|
| 437 |
/* A type that is properly aligned for any stack member. */ |
| 438 |
union yyalloc |
| 439 |
{ |
| 440 |
yytype_int16 yyss_alloc; |
| 441 |
YYSTYPE yyvs_alloc; |
| 442 |
}; |
| 443 |
|
| 444 |
/* The size of the maximum gap between one aligned stack and the next. */ |
| 445 |
# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) |
| 446 |
|
| 447 |
/* The size of an array large to enough to hold all stacks, each with |
| 448 |
N elements. */ |
| 449 |
# define YYSTACK_BYTES(N) \ |
| 450 |
((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ |
| 451 |
+ YYSTACK_GAP_MAXIMUM) |
| 452 |
|
| 453 |
# define YYCOPY_NEEDED 1 |
| 454 |
|
| 455 |
/* Relocate STACK from its old location to the new one. The |
| 456 |
local variables YYSIZE and YYSTACKSIZE give the old and new number of |
| 457 |
elements in the stack, and YYPTR gives the new location of the |
| 458 |
stack. Advance YYPTR to a properly aligned location for the next |
| 459 |
stack. */ |
| 460 |
# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ |
| 461 |
do \ |
| 462 |
{ \ |
| 463 |
YYSIZE_T yynewbytes; \ |
| 464 |
YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ |
| 465 |
Stack = &yyptr->Stack_alloc; \ |
| 466 |
yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ |
| 467 |
yyptr += yynewbytes / sizeof (*yyptr); \ |
| 468 |
} \ |
| 469 |
while (0) |
| 470 |
|
| 471 |
#endif |
| 472 |
|
| 473 |
#if defined YYCOPY_NEEDED && YYCOPY_NEEDED |
| 474 |
/* Copy COUNT objects from SRC to DST. The source and destination do |
| 475 |
not overlap. */ |
| 476 |
# ifndef YYCOPY |
| 477 |
# if defined __GNUC__ && 1 < __GNUC__ |
| 478 |
# define YYCOPY(Dst, Src, Count) \ |
| 479 |
__builtin_memcpy (Dst, Src, (Count) * sizeof (*(Src))) |
| 480 |
# else |
| 481 |
# define YYCOPY(Dst, Src, Count) \ |
| 482 |
do \ |
| 483 |
{ \ |
| 484 |
YYSIZE_T yyi; \ |
| 485 |
for (yyi = 0; yyi < (Count); yyi++) \ |
| 486 |
(Dst)[yyi] = (Src)[yyi]; \ |
| 487 |
} \ |
| 488 |
while (0) |
| 489 |
# endif |
| 490 |
# endif |
| 491 |
#endif /* !YYCOPY_NEEDED */ |
| 492 |
|
| 493 |
/* YYFINAL -- State number of the termination state. */ |
| 494 |
#define YYFINAL 2 |
| 495 |
/* YYLAST -- Last index in YYTABLE. */ |
| 496 |
#define YYLAST 301 |
| 497 |
|
| 498 |
/* YYNTOKENS -- Number of terminals. */ |
| 499 |
#define YYNTOKENS 64 |
| 500 |
/* YYNNTS -- Number of nonterminals. */ |
| 501 |
#define YYNNTS 78 |
| 502 |
/* YYNRULES -- Number of rules. */ |
| 503 |
#define YYNRULES 147 |
| 504 |
/* YYNSTATES -- Number of states. */ |
| 505 |
#define YYNSTATES 319 |
| 506 |
|
| 507 |
/* YYTRANSLATE[YYX] -- Symbol number corresponding to YYX as returned |
| 508 |
by yylex, with out-of-bounds checking. */ |
| 509 |
#define YYUNDEFTOK 2 |
| 510 |
#define YYMAXUTOK 313 |
| 511 |
|
| 512 |
#define YYTRANSLATE(YYX) \ |
| 513 |
((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) |
| 514 |
|
| 515 |
/* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM |
| 516 |
as returned by yylex, without out-of-bounds checking. */ |
| 517 |
static const yytype_uint8 yytranslate[] = |
| 518 |
{ |
| 519 |
0, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 520 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 521 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 522 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 523 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 524 |
2, 2, 2, 2, 2, 2, 2, 2, 63, 61, |
| 525 |
2, 62, 2, 2, 2, 2, 2, 2, 2, 2, |
| 526 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 527 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 528 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 529 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 530 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 531 |
2, 2, 2, 59, 2, 60, 2, 2, 2, 2, |
| 532 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 533 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 534 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 535 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 536 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 537 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 538 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 539 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 540 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 541 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 542 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 543 |
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, |
| 544 |
2, 2, 2, 2, 2, 2, 1, 2, 3, 4, |
| 545 |
5, 6, 7, 8, 9, 10, 11, 12, 13, 14, |
| 546 |
15, 16, 17, 18, 19, 20, 21, 22, 23, 24, |
| 547 |
25, 26, 27, 28, 29, 30, 31, 32, 33, 34, |
| 548 |
35, 36, 37, 38, 39, 40, 41, 42, 43, 44, |
| 549 |
45, 46, 47, 48, 49, 50, 51, 52, 53, 54, |
| 550 |
55, 56, 57, 58 |
| 551 |
}; |
| 552 |
|
| 553 |
#if YYDEBUG |
| 554 |
/* YYRLINE[YYN] -- Source line where rule number YYN was defined. */ |
| 555 |
static const yytype_uint16 yyrline[] = |
| 556 |
{ |
| 557 |
0, 100, 100, 101, 104, 105, 106, 107, 108, 109, |
| 558 |
111, 111, 112, 113, 114, 115, 116, 117, 118, 119, |
| 559 |
122, 122, 123, 124, 125, 126, 131, 133, 134, 136, |
| 560 |
137, 138, 139, 140, 142, 147, 153, 158, 166, 168, |
| 561 |
169, 171, 172, 173, 174, 175, 176, 177, 178, 179, |
| 562 |
180, 181, 182, 183, 184, 185, 186, 188, 194, 200, |
| 563 |
206, 212, 218, 224, 230, 238, 243, 249, 255, 261, |
| 564 |
267, 277, 277, 294, 295, 297, 298, 299, 301, 309, |
| 565 |
317, 328, 328, 344, 345, 347, 348, 349, 351, 361, |
| 566 |
374, 374, 419, 420, 422, 423, 424, 425, 426, 427, |
| 567 |
428, 429, 430, 431, 433, 440, 447, 454, 470, 476, |
| 568 |
482, 488, 494, 513, 515, 516, 518, 519, 520, 521, |
| 569 |
522, 524, 530, 536, 545, 545, 564, 565, 567, 568, |
| 570 |
569, 570, 571, 572, 574, 581, 588, 599, 605, 607, |
| 571 |
608, 610, 628, 630, 631, 633, 634, 636 |
| 572 |
}; |
| 573 |
#endif |
| 574 |
|
| 575 |
#if YYDEBUG || YYERROR_VERBOSE || 0 |
| 576 |
/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. |
| 577 |
First, the terminals, then, starting at YYNTOKENS, nonterminals. */ |
| 578 |
static const char *const yytname[] = |
| 579 |
{ |
| 580 |
"$end", "error", "$undefined", "AWAY", "BAN_UNKNOWN", "BLACKLIST", |
| 581 |
"BYTES", "KBYTES", "MBYTES", "CHANNEL", "CONNREGEX", "DNS_FDLIMIT", |
| 582 |
"DNSBL_FROM", "DNSBL_TO", "EXEMPT", "FD", "INVITE", "IRC", "KLINE", |
| 583 |
"KEY", "MASK", "MAX_READ", "MODE", "NAME", "NEGCACHE", "NICK", |
| 584 |
"NICKSERV", "OPER", "OPM", "OPTIONS", "PASSWORD", "PERFORM", "PIDFILE", |
| 585 |
"PORT", "PROTOCOL", "REALNAME", "REPLY", "SCANLOG", "SCANNER", "SECONDS", |
| 586 |
"MINUTES", "HOURS", "DAYS", "WEEKS", "MONTHS", "YEARS", "SENDMAIL", |
| 587 |
"SERVER", "TARGET_IP", "TARGET_PORT", "TARGET_STRING", "TIMEOUT", "TYPE", |
| 588 |
"USERNAME", "USER", "VHOST", "NUMBER", "STRING", "PROTOCOLTYPE", "'{'", |
| 589 |
"'}'", "';'", "'='", "':'", "$accept", "config", "config_items", |
| 590 |
"timespec_", "timespec", "sizespec_", "sizespec", "options_entry", |
| 591 |
"options_items", "options_item", "options_negcache", "options_pidfile", |
| 592 |
"options_dns_fdlimit", "options_scanlog", "irc_entry", "irc_items", |
| 593 |
"irc_item", "irc_away", "irc_kline", "irc_mode", "irc_nick", |
| 594 |
"irc_nickserv", "irc_oper", "irc_password", "irc_perform", "irc_port", |
| 595 |
"irc_realname", "irc_server", "irc_username", "irc_vhost", |
| 596 |
"irc_connregex", "channel_entry", "$@1", "channel_items", "channel_item", |
| 597 |
"channel_name", "channel_key", "channel_invite", "user_entry", "$@2", |
| 598 |
"user_items", "user_item", "user_mask", "user_scanner", "scanner_entry", |
| 599 |
"$@3", "scanner_items", "scanner_item", "scanner_name", "scanner_vhost", |
| 600 |
"scanner_target_ip", "scanner_target_string", "scanner_fd", |
| 601 |
"scanner_target_port", "scanner_timeout", "scanner_max_read", |
| 602 |
"scanner_protocol", "opm_entry", "opm_items", "opm_item", |
| 603 |
"opm_dnsbl_from", "opm_dnsbl_to", "opm_sendmail", "opm_blacklist_entry", |
| 604 |
"$@4", "blacklist_items", "blacklist_item", "blacklist_name", |
| 605 |
"blacklist_kline", "blacklist_type", "blacklist_ban_unknown", |
| 606 |
"blacklist_reply", "blacklist_reply_items", "blacklist_reply_item", |
| 607 |
"exempt_entry", "exempt_items", "exempt_item", "exempt_mask", YY_NULLPTR |
| 608 |
}; |
| 609 |
#endif |
| 610 |
|
| 611 |
# ifdef YYPRINT |
| 612 |
/* YYTOKNUM[NUM] -- (External) token number corresponding to the |
| 613 |
(internal) symbol number NUM (which must be that of a token). */ |
| 614 |
static const yytype_uint16 yytoknum[] = |
| 615 |
{ |
| 616 |
0, 256, 257, 258, 259, 260, 261, 262, 263, 264, |
| 617 |
265, 266, 267, 268, 269, 270, 271, 272, 273, 274, |
| 618 |
275, 276, 277, 278, 279, 280, 281, 282, 283, 284, |
| 619 |
285, 286, 287, 288, 289, 290, 291, 292, 293, 294, |
| 620 |
295, 296, 297, 298, 299, 300, 301, 302, 303, 304, |
| 621 |
305, 306, 307, 308, 309, 310, 311, 312, 313, 123, |
| 622 |
125, 59, 61, 58 |
| 623 |
}; |
| 624 |
# endif |
| 625 |
|
| 626 |
#define YYPACT_NINF -157 |
| 627 |
|
| 628 |
#define yypact_value_is_default(Yystate) \ |
| 629 |
(!!((Yystate) == (-157))) |
| 630 |
|
| 631 |
#define YYTABLE_NINF -125 |
| 632 |
|
| 633 |
#define yytable_value_is_error(Yytable_value) \ |
| 634 |
0 |
| 635 |
|
| 636 |
/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing |
| 637 |
STATE-NUM. */ |
| 638 |
static const yytype_int16 yypact[] = |
| 639 |
{ |
| 640 |
-157, 126, -157, -52, -48, -40, -36, -157, -157, -157, |
| 641 |
-157, -49, -157, -9, -157, -157, 39, 80, 83, 136, |
| 642 |
-22, -18, -157, -17, 19, -157, -157, -157, -16, -10, |
| 643 |
-4, 4, 12, 23, 24, 30, 32, 37, 42, 56, |
| 644 |
62, 66, 0, -157, -157, -157, -157, -157, -157, -157, |
| 645 |
-157, -157, -157, -157, -157, -157, -157, -157, -157, 59, |
| 646 |
-157, 68, 69, 72, 3, -157, -157, -157, -157, -157, |
| 647 |
133, -157, 77, 79, 82, 84, 33, -157, -157, -157, |
| 648 |
-157, -157, 16, 102, 44, 81, -157, 88, 92, 99, |
| 649 |
101, 104, 105, 106, 108, 109, 103, 110, 112, 113, |
| 650 |
114, 111, -157, 129, 132, 137, 138, 131, -157, 134, |
| 651 |
140, 141, 142, 143, 144, -157, -157, 128, 139, 31, |
| 652 |
-157, -157, -157, -157, 145, 146, 147, 148, 149, 150, |
| 653 |
151, 152, 153, 27, -157, -157, -157, -157, -157, -157, |
| 654 |
-157, -157, -157, -157, 155, -157, 156, 157, 158, 159, |
| 655 |
160, 161, 162, 163, 164, 165, 166, 167, 168, 169, |
| 656 |
-157, 93, 170, 171, 172, -157, 96, 173, 135, 174, |
| 657 |
175, 176, -157, 181, 182, 179, -157, 185, 186, 187, |
| 658 |
188, 190, 189, 191, 141, 192, 193, -157, -157, -157, |
| 659 |
-157, -157, -157, -157, -157, -157, -157, -157, -157, -157, |
| 660 |
-157, -157, -157, 194, 195, 196, 48, -157, -157, -157, |
| 661 |
-157, -157, -157, -157, -157, 197, 198, 199, 184, 200, |
| 662 |
20, -157, -157, -157, -157, -157, -157, -157, 141, 141, |
| 663 |
141, 141, 141, 141, 141, -157, -157, -157, -157, -157, |
| 664 |
202, 203, -157, 204, 6, 205, 206, 207, 208, 210, |
| 665 |
211, 212, 213, -157, 218, 219, 220, 217, -157, 223, |
| 666 |
224, 225, 227, 228, 226, -157, -157, -157, -157, -157, |
| 667 |
-157, -157, -157, -157, -157, -157, 186, 186, 186, -157, |
| 668 |
-157, -157, -157, 230, -157, -157, -157, -157, -157, 229, |
| 669 |
231, 232, -157, 233, 234, 235, 222, -54, -157, 236, |
| 670 |
-157, -157, -157, -157, 237, -157, -157, -157, -157, -157, |
| 671 |
-157, 242, 239, -157, -157, -157, 240, -157, -157 |
| 672 |
}; |
| 673 |
|
| 674 |
/* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM. |
| 675 |
Performed when YYTABLE does not specify something else to do. Zero |
| 676 |
means the default is an error. */ |
| 677 |
static const yytype_uint8 yydefact[] = |
| 678 |
{ |
| 679 |
2, 81, 1, 0, 0, 0, 0, 3, 5, 4, |
| 680 |
7, 0, 8, 0, 6, 9, 0, 0, 0, 0, |
| 681 |
0, 0, 146, 0, 0, 144, 145, 56, 0, 0, |
| 682 |
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, |
| 683 |
0, 0, 0, 40, 41, 43, 46, 44, 45, 47, |
| 684 |
48, 54, 49, 50, 51, 52, 53, 42, 55, 0, |
| 685 |
120, 0, 0, 0, 0, 115, 116, 117, 118, 119, |
| 686 |
0, 33, 0, 0, 0, 0, 0, 28, 29, 30, |
| 687 |
31, 32, 0, 0, 0, 0, 143, 0, 0, 0, |
| 688 |
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, |
| 689 |
0, 0, 39, 0, 0, 0, 0, 0, 114, 0, |
| 690 |
0, 0, 0, 0, 0, 27, 87, 0, 0, 0, |
| 691 |
84, 85, 86, 103, 0, 0, 0, 0, 0, 0, |
| 692 |
0, 0, 0, 0, 93, 94, 95, 97, 99, 96, |
| 693 |
98, 101, 102, 100, 0, 142, 0, 0, 0, 0, |
| 694 |
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, |
| 695 |
38, 0, 0, 0, 0, 113, 0, 0, 10, 0, |
| 696 |
0, 0, 26, 0, 0, 0, 83, 0, 0, 0, |
| 697 |
0, 0, 0, 0, 0, 0, 0, 92, 147, 57, |
| 698 |
70, 58, 59, 60, 61, 62, 63, 64, 65, 66, |
| 699 |
67, 68, 69, 0, 0, 0, 0, 74, 75, 76, |
| 700 |
77, 121, 122, 123, 133, 0, 0, 0, 0, 0, |
| 701 |
0, 127, 128, 130, 129, 131, 132, 36, 10, 10, |
| 702 |
10, 10, 10, 10, 10, 12, 11, 34, 35, 37, |
| 703 |
0, 0, 82, 0, 20, 0, 0, 0, 0, 0, |
| 704 |
0, 0, 0, 91, 0, 0, 0, 0, 73, 0, |
| 705 |
0, 0, 0, 0, 0, 126, 13, 14, 15, 16, |
| 706 |
17, 18, 19, 88, 89, 108, 20, 20, 20, 22, |
| 707 |
21, 111, 104, 0, 106, 109, 107, 110, 105, 0, |
| 708 |
0, 0, 72, 0, 0, 0, 0, 0, 140, 0, |
| 709 |
125, 23, 24, 25, 0, 80, 79, 78, 137, 135, |
| 710 |
134, 0, 0, 139, 136, 112, 0, 138, 141 |
| 711 |
}; |
| 712 |
|
| 713 |
/* YYPGOTO[NTERM-NUM]. */ |
| 714 |
static const yytype_int16 yypgoto[] = |
| 715 |
{ |
| 716 |
-157, -157, -157, -47, -111, -156, 25, -157, -157, 122, |
| 717 |
-157, -157, -157, -157, -157, -157, 209, -157, -157, -157, |
| 718 |
-157, -157, -157, -157, -157, -157, -157, -157, -157, -157, |
| 719 |
-157, -157, -157, -157, -2, -157, -157, -157, -157, -157, |
| 720 |
-157, 87, -157, -157, -157, -157, -157, 117, -157, -157, |
| 721 |
-157, -157, -157, -157, -157, -157, -157, -157, -157, 216, |
| 722 |
-157, -157, -157, -157, -157, -157, 35, -157, -157, -157, |
| 723 |
-157, -157, -157, -95, -157, -157, 244, -157 |
| 724 |
}; |
| 725 |
|
| 726 |
/* YYDEFGOTO[NTERM-NUM]. */ |
| 727 |
static const yytype_int16 yydefgoto[] = |
| 728 |
{ |
| 729 |
-1, 1, 7, 235, 236, 279, 280, 8, 76, 77, |
| 730 |
78, 79, 80, 81, 9, 42, 43, 44, 45, 46, |
| 731 |
47, 48, 49, 50, 51, 52, 53, 54, 55, 56, |
| 732 |
57, 58, 59, 206, 207, 208, 209, 210, 10, 11, |
| 733 |
119, 120, 121, 122, 12, 13, 133, 134, 135, 136, |
| 734 |
137, 138, 139, 140, 141, 142, 143, 14, 64, 65, |
| 735 |
66, 67, 68, 69, 70, 220, 221, 222, 223, 224, |
| 736 |
225, 226, 297, 298, 15, 24, 25, 26 |
| 737 |
}; |
| 738 |
|
| 739 |
/* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If |
| 740 |
positive, shift that token. If negative, reduce the rule whose |
| 741 |
number is the opposite. If YYTABLE_NINF, syntax error. */ |
| 742 |
static const yytype_int16 yytable[] = |
| 743 |
{ |
| 744 |
169, 27, 296, 28, 60, 20, 312, 16, -124, -71, |
| 745 |
29, 17, 276, 277, 278, 61, 62, 116, 30, 18, |
| 746 |
22, 214, 31, 19, 215, 32, 33, 34, 123, 21, |
| 747 |
35, 36, 116, 37, 71, 38, 117, 82, 216, 23, |
| 748 |
22, 83, 124, 217, 72, 84, 87, 39, 125, 63, |
| 749 |
126, 117, 88, 40, 118, 41, 218, 73, 89, 23, |
| 750 |
101, 127, 244, 107, 203, 74, 90, 204, 103, 118, |
| 751 |
75, 205, 219, 251, 91, 128, 129, 130, 131, 85, |
| 752 |
264, 27, 132, 28, 60, 92, 93, 186, -124, -71, |
| 753 |
29, 175, 94, 114, 95, 61, 62, 214, 30, 96, |
| 754 |
215, 144, 31, 123, 97, 32, 33, 34, 257, 203, |
| 755 |
35, 36, 204, 37, 216, 38, 205, 124, 98, 217, |
| 756 |
301, 302, 303, 125, 99, 126, 2, 39, 100, 63, |
| 757 |
104, 105, 218, 40, 106, 41, 127, 71, 109, 110, |
| 758 |
3, 111, 145, 4, 112, 146, 113, 72, 219, 147, |
| 759 |
128, 129, 130, 131, 5, 6, 148, 132, 149, 155, |
| 760 |
73, 150, 151, 152, -90, 153, 154, 156, 74, 157, |
| 761 |
158, 159, 160, 75, 228, 229, 230, 231, 232, 233, |
| 762 |
234, 266, 267, 268, 269, 270, 271, 272, 161, 162, |
| 763 |
173, 168, 165, 166, 163, 164, 167, 168, 115, 170, |
| 764 |
171, 174, 313, 245, 258, 172, 176, 177, 178, 179, |
| 765 |
180, 181, 182, 183, 184, 185, 188, 189, 190, 191, |
| 766 |
192, 193, 194, 195, 196, 197, 198, 199, 200, 201, |
| 767 |
202, 211, 212, 213, 227, 237, 238, 239, 240, 241, |
| 768 |
242, 243, 244, 262, 246, 249, 247, 248, 250, 252, |
| 769 |
187, 102, 0, 0, 253, 265, 254, 255, 256, 259, |
| 770 |
260, 261, 263, 273, 274, 275, 281, 282, 86, 284, |
| 771 |
283, 285, 286, 287, 288, 289, 290, 291, 292, 293, |
| 772 |
108, 294, 295, 296, 311, 299, 304, 300, 0, 0, |
| 773 |
305, 0, 306, 307, 308, 309, 310, 314, 315, 316, |
| 774 |
317, 318 |
| 775 |
}; |
| 776 |
|
| 777 |
static const yytype_int16 yycheck[] = |
| 778 |
{ |
| 779 |
111, 1, 56, 3, 1, 54, 60, 59, 5, 9, |
| 780 |
10, 59, 6, 7, 8, 12, 13, 1, 18, 59, |
| 781 |
1, 1, 22, 59, 4, 25, 26, 27, 1, 38, |
| 782 |
30, 31, 1, 33, 1, 35, 20, 59, 18, 20, |
| 783 |
1, 59, 15, 23, 11, 62, 62, 47, 21, 46, |
| 784 |
23, 20, 62, 53, 38, 55, 36, 24, 62, 20, |
| 785 |
60, 34, 56, 60, 16, 32, 62, 19, 9, 38, |
| 786 |
37, 23, 52, 184, 62, 48, 49, 50, 51, 60, |
| 787 |
60, 1, 55, 3, 1, 62, 62, 60, 5, 9, |
| 788 |
10, 60, 62, 60, 62, 12, 13, 1, 18, 62, |
| 789 |
4, 57, 22, 1, 62, 25, 26, 27, 60, 16, |
| 790 |
30, 31, 19, 33, 18, 35, 23, 15, 62, 23, |
| 791 |
276, 277, 278, 21, 62, 23, 0, 47, 62, 46, |
| 792 |
62, 62, 36, 53, 62, 55, 34, 1, 5, 62, |
| 793 |
14, 62, 61, 17, 62, 57, 62, 11, 52, 57, |
| 794 |
48, 49, 50, 51, 28, 29, 57, 55, 57, 56, |
| 795 |
24, 57, 57, 57, 38, 57, 57, 57, 32, 57, |
| 796 |
57, 57, 61, 37, 39, 40, 41, 42, 43, 44, |
| 797 |
45, 228, 229, 230, 231, 232, 233, 234, 59, 57, |
| 798 |
62, 56, 61, 59, 57, 57, 56, 56, 76, 57, |
| 799 |
57, 62, 297, 178, 206, 61, 119, 62, 62, 62, |
| 800 |
62, 62, 62, 62, 62, 62, 61, 61, 61, 61, |
| 801 |
61, 61, 61, 61, 61, 61, 61, 61, 61, 61, |
| 802 |
61, 61, 61, 61, 61, 61, 61, 61, 57, 57, |
| 803 |
61, 56, 56, 59, 57, 56, 58, 57, 57, 57, |
| 804 |
133, 42, -1, -1, 61, 220, 62, 62, 62, 62, |
| 805 |
62, 62, 62, 61, 61, 61, 61, 61, 24, 61, |
| 806 |
63, 61, 61, 61, 61, 57, 57, 57, 61, 56, |
| 807 |
64, 57, 57, 56, 62, 57, 56, 61, -1, -1, |
| 808 |
61, -1, 61, 61, 61, 61, 61, 61, 61, 57, |
| 809 |
61, 61 |
| 810 |
}; |
| 811 |
|
| 812 |
/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing |
| 813 |
symbol of state STATE-NUM. */ |
| 814 |
static const yytype_uint8 yystos[] = |
| 815 |
{ |
| 816 |
0, 65, 0, 14, 17, 28, 29, 66, 71, 78, |
| 817 |
102, 103, 108, 109, 121, 138, 59, 59, 59, 59, |
| 818 |
54, 38, 1, 20, 139, 140, 141, 1, 3, 10, |
| 819 |
18, 22, 25, 26, 27, 30, 31, 33, 35, 47, |
| 820 |
53, 55, 79, 80, 81, 82, 83, 84, 85, 86, |
| 821 |
87, 88, 89, 90, 91, 92, 93, 94, 95, 96, |
| 822 |
1, 12, 13, 46, 122, 123, 124, 125, 126, 127, |
| 823 |
128, 1, 11, 24, 32, 37, 72, 73, 74, 75, |
| 824 |
76, 77, 59, 59, 62, 60, 140, 62, 62, 62, |
| 825 |
62, 62, 62, 62, 62, 62, 62, 62, 62, 62, |
| 826 |
62, 60, 80, 9, 62, 62, 62, 60, 123, 5, |
| 827 |
62, 62, 62, 62, 60, 73, 1, 20, 38, 104, |
| 828 |
105, 106, 107, 1, 15, 21, 23, 34, 48, 49, |
| 829 |
50, 51, 55, 110, 111, 112, 113, 114, 115, 116, |
| 830 |
117, 118, 119, 120, 57, 61, 57, 57, 57, 57, |
| 831 |
57, 57, 57, 57, 57, 56, 57, 57, 57, 57, |
| 832 |
61, 59, 57, 57, 57, 61, 59, 56, 56, 68, |
| 833 |
57, 57, 61, 62, 62, 60, 105, 62, 62, 62, |
| 834 |
62, 62, 62, 62, 62, 62, 60, 111, 61, 61, |
| 835 |
61, 61, 61, 61, 61, 61, 61, 61, 61, 61, |
| 836 |
61, 61, 61, 16, 19, 23, 97, 98, 99, 100, |
| 837 |
101, 61, 61, 61, 1, 4, 18, 23, 36, 52, |
| 838 |
129, 130, 131, 132, 133, 134, 135, 61, 39, 40, |
| 839 |
41, 42, 43, 44, 45, 67, 68, 61, 61, 61, |
| 840 |
57, 57, 61, 56, 56, 70, 57, 58, 57, 56, |
| 841 |
57, 68, 57, 61, 62, 62, 62, 60, 98, 62, |
| 842 |
62, 62, 59, 62, 60, 130, 67, 67, 67, 67, |
| 843 |
67, 67, 67, 61, 61, 61, 6, 7, 8, 69, |
| 844 |
70, 61, 61, 63, 61, 61, 61, 61, 61, 57, |
| 845 |
57, 57, 61, 56, 57, 57, 56, 136, 137, 57, |
| 846 |
61, 69, 69, 69, 56, 61, 61, 61, 61, 61, |
| 847 |
61, 62, 60, 137, 61, 61, 57, 61, 61 |
| 848 |
}; |
| 849 |
|
| 850 |
/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ |
| 851 |
static const yytype_uint8 yyr1[] = |
| 852 |
{ |
| 853 |
0, 64, 65, 65, 66, 66, 66, 66, 66, 66, |
| 854 |
67, 67, 68, 68, 68, 68, 68, 68, 68, 68, |
| 855 |
69, 69, 70, 70, 70, 70, 71, 72, 72, 73, |
| 856 |
73, 73, 73, 73, 74, 75, 76, 77, 78, 79, |
| 857 |
79, 80, 80, 80, 80, 80, 80, 80, 80, 80, |
| 858 |
80, 80, 80, 80, 80, 80, 80, 81, 82, 83, |
| 859 |
84, 85, 86, 87, 88, 89, 90, 91, 92, 93, |
| 860 |
94, 96, 95, 97, 97, 98, 98, 98, 99, 100, |
| 861 |
101, 103, 102, 104, 104, 105, 105, 105, 106, 107, |
| 862 |
109, 108, 110, 110, 111, 111, 111, 111, 111, 111, |
| 863 |
111, 111, 111, 111, 112, 113, 114, 115, 116, 117, |
| 864 |
118, 119, 120, 121, 122, 122, 123, 123, 123, 123, |
| 865 |
123, 124, 125, 126, 128, 127, 129, 129, 130, 130, |
| 866 |
130, 130, 130, 130, 131, 132, 133, 134, 135, 136, |
| 867 |
136, 137, 138, 139, 139, 140, 140, 141 |
| 868 |
}; |
| 869 |
|
| 870 |
/* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */ |
| 871 |
static const yytype_uint8 yyr2[] = |
| 872 |
{ |
| 873 |
0, 2, 0, 2, 1, 1, 1, 1, 1, 1, |
| 874 |
0, 1, 2, 3, 3, 3, 3, 3, 3, 3, |
| 875 |
0, 1, 2, 3, 3, 3, 5, 2, 1, 1, |
| 876 |
1, 1, 1, 1, 4, 4, 4, 4, 5, 2, |
| 877 |
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, |
| 878 |
1, 1, 1, 1, 1, 1, 1, 4, 4, 4, |
| 879 |
4, 4, 4, 4, 4, 4, 4, 4, 4, 4, |
| 880 |
4, 0, 6, 2, 1, 1, 1, 1, 4, 4, |
| 881 |
4, 0, 6, 2, 1, 1, 1, 1, 4, 4, |
| 882 |
0, 6, 2, 1, 1, 1, 1, 1, 1, 1, |
| 883 |
1, 1, 1, 1, 4, 4, 4, 4, 4, 4, |
| 884 |
4, 4, 6, 5, 2, 1, 1, 1, 1, 1, |
| 885 |
1, 4, 4, 4, 0, 6, 2, 1, 1, 1, |
| 886 |
1, 1, 1, 1, 4, 4, 4, 4, 5, 2, |
| 887 |
1, 4, 5, 2, 1, 1, 1, 4 |
| 888 |
}; |
| 889 |
|
| 890 |
|
| 891 |
#define yyerrok (yyerrstatus = 0) |
| 892 |
#define yyclearin (yychar = YYEMPTY) |
| 893 |
#define YYEMPTY (-2) |
| 894 |
#define YYEOF 0 |
| 895 |
|
| 896 |
#define YYACCEPT goto yyacceptlab |
| 897 |
#define YYABORT goto yyabortlab |
| 898 |
#define YYERROR goto yyerrorlab |
| 899 |
|
| 900 |
|
| 901 |
#define YYRECOVERING() (!!yyerrstatus) |
| 902 |
|
| 903 |
#define YYBACKUP(Token, Value) \ |
| 904 |
do \ |
| 905 |
if (yychar == YYEMPTY) \ |
| 906 |
{ \ |
| 907 |
yychar = (Token); \ |
| 908 |
yylval = (Value); \ |
| 909 |
YYPOPSTACK (yylen); \ |
| 910 |
yystate = *yyssp; \ |
| 911 |
goto yybackup; \ |
| 912 |
} \ |
| 913 |
else \ |
| 914 |
{ \ |
| 915 |
yyerror (YY_("syntax error: cannot back up")); \ |
| 916 |
YYERROR; \ |
| 917 |
} \ |
| 918 |
while (0) |
| 919 |
|
| 920 |
/* Error token number */ |
| 921 |
#define YYTERROR 1 |
| 922 |
#define YYERRCODE 256 |
| 923 |
|
| 924 |
|
| 925 |
|
| 926 |
/* Enable debugging if requested. */ |
| 927 |
#if YYDEBUG |
| 928 |
|
| 929 |
# ifndef YYFPRINTF |
| 930 |
# include <stdio.h> /* INFRINGES ON USER NAME SPACE */ |
| 931 |
# define YYFPRINTF fprintf |
| 932 |
# endif |
| 933 |
|
| 934 |
# define YYDPRINTF(Args) \ |
| 935 |
do { \ |
| 936 |
if (yydebug) \ |
| 937 |
YYFPRINTF Args; \ |
| 938 |
} while (0) |
| 939 |
|
| 940 |
/* This macro is provided for backward compatibility. */ |
| 941 |
#ifndef YY_LOCATION_PRINT |
| 942 |
# define YY_LOCATION_PRINT(File, Loc) ((void) 0) |
| 943 |
#endif |
| 944 |
|
| 945 |
|
| 946 |
# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ |
| 947 |
do { \ |
| 948 |
if (yydebug) \ |
| 949 |
{ \ |
| 950 |
YYFPRINTF (stderr, "%s ", Title); \ |
| 951 |
yy_symbol_print (stderr, \ |
| 952 |
Type, Value); \ |
| 953 |
YYFPRINTF (stderr, "\n"); \ |
| 954 |
} \ |
| 955 |
} while (0) |
| 956 |
|
| 957 |
|
| 958 |
/*----------------------------------------. |
| 959 |
| Print this symbol's value on YYOUTPUT. | |
| 960 |
`----------------------------------------*/ |
| 961 |
|
| 962 |
static void |
| 963 |
yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) |
| 964 |
{ |
| 965 |
FILE *yyo = yyoutput; |
| 966 |
YYUSE (yyo); |
| 967 |
if (!yyvaluep) |
| 968 |
return; |
| 969 |
# ifdef YYPRINT |
| 970 |
if (yytype < YYNTOKENS) |
| 971 |
YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); |
| 972 |
# endif |
| 973 |
YYUSE (yytype); |
| 974 |
} |
| 975 |
|
| 976 |
|
| 977 |
/*--------------------------------. |
| 978 |
| Print this symbol on YYOUTPUT. | |
| 979 |
`--------------------------------*/ |
| 980 |
|
| 981 |
static void |
| 982 |
yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) |
| 983 |
{ |
| 984 |
YYFPRINTF (yyoutput, "%s %s (", |
| 985 |
yytype < YYNTOKENS ? "token" : "nterm", yytname[yytype]); |
| 986 |
|
| 987 |
yy_symbol_value_print (yyoutput, yytype, yyvaluep); |
| 988 |
YYFPRINTF (yyoutput, ")"); |
| 989 |
} |
| 990 |
|
| 991 |
/*------------------------------------------------------------------. |
| 992 |
| yy_stack_print -- Print the state stack from its BOTTOM up to its | |
| 993 |
| TOP (included). | |
| 994 |
`------------------------------------------------------------------*/ |
| 995 |
|
| 996 |
static void |
| 997 |
yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) |
| 998 |
{ |
| 999 |
YYFPRINTF (stderr, "Stack now"); |
| 1000 |
for (; yybottom <= yytop; yybottom++) |
| 1001 |
{ |
| 1002 |
int yybot = *yybottom; |
| 1003 |
YYFPRINTF (stderr, " %d", yybot); |
| 1004 |
} |
| 1005 |
YYFPRINTF (stderr, "\n"); |
| 1006 |
} |
| 1007 |
|
| 1008 |
# define YY_STACK_PRINT(Bottom, Top) \ |
| 1009 |
do { \ |
| 1010 |
if (yydebug) \ |
| 1011 |
yy_stack_print ((Bottom), (Top)); \ |
| 1012 |
} while (0) |
| 1013 |
|
| 1014 |
|
| 1015 |
/*------------------------------------------------. |
| 1016 |
| Report that the YYRULE is going to be reduced. | |
| 1017 |
`------------------------------------------------*/ |
| 1018 |
|
| 1019 |
static void |
| 1020 |
yy_reduce_print (yytype_int16 *yyssp, YYSTYPE *yyvsp, int yyrule) |
| 1021 |
{ |
| 1022 |
unsigned long int yylno = yyrline[yyrule]; |
| 1023 |
int yynrhs = yyr2[yyrule]; |
| 1024 |
int yyi; |
| 1025 |
YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", |
| 1026 |
yyrule - 1, yylno); |
| 1027 |
/* The symbols being reduced. */ |
| 1028 |
for (yyi = 0; yyi < yynrhs; yyi++) |
| 1029 |
{ |
| 1030 |
YYFPRINTF (stderr, " $%d = ", yyi + 1); |
| 1031 |
yy_symbol_print (stderr, |
| 1032 |
yystos[yyssp[yyi + 1 - yynrhs]], |
| 1033 |
&(yyvsp[(yyi + 1) - (yynrhs)]) |
| 1034 |
); |
| 1035 |
YYFPRINTF (stderr, "\n"); |
| 1036 |
} |
| 1037 |
} |
| 1038 |
|
| 1039 |
# define YY_REDUCE_PRINT(Rule) \ |
| 1040 |
do { \ |
| 1041 |
if (yydebug) \ |
| 1042 |
yy_reduce_print (yyssp, yyvsp, Rule); \ |
| 1043 |
} while (0) |
| 1044 |
|
| 1045 |
/* Nonzero means print parse trace. It is left uninitialized so that |
| 1046 |
multiple parsers can coexist. */ |
| 1047 |
int yydebug; |
| 1048 |
#else /* !YYDEBUG */ |
| 1049 |
# define YYDPRINTF(Args) |
| 1050 |
# define YY_SYMBOL_PRINT(Title, Type, Value, Location) |
| 1051 |
# define YY_STACK_PRINT(Bottom, Top) |
| 1052 |
# define YY_REDUCE_PRINT(Rule) |
| 1053 |
#endif /* !YYDEBUG */ |
| 1054 |
|
| 1055 |
|
| 1056 |
/* YYINITDEPTH -- initial size of the parser's stacks. */ |
| 1057 |
#ifndef YYINITDEPTH |
| 1058 |
# define YYINITDEPTH 200 |
| 1059 |
#endif |
| 1060 |
|
| 1061 |
/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only |
| 1062 |
if the built-in stack extension method is used). |
| 1063 |
|
| 1064 |
Do not make this value too large; the results are undefined if |
| 1065 |
YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) |
| 1066 |
evaluated with infinite-precision integer arithmetic. */ |
| 1067 |
|
| 1068 |
#ifndef YYMAXDEPTH |
| 1069 |
# define YYMAXDEPTH 10000 |
| 1070 |
#endif |
| 1071 |
|
| 1072 |
|
| 1073 |
#if YYERROR_VERBOSE |
| 1074 |
|
| 1075 |
# ifndef yystrlen |
| 1076 |
# if defined __GLIBC__ && defined _STRING_H |
| 1077 |
# define yystrlen strlen |
| 1078 |
# else |
| 1079 |
/* Return the length of YYSTR. */ |
| 1080 |
static YYSIZE_T |
| 1081 |
yystrlen (const char *yystr) |
| 1082 |
{ |
| 1083 |
YYSIZE_T yylen; |
| 1084 |
for (yylen = 0; yystr[yylen]; yylen++) |
| 1085 |
continue; |
| 1086 |
return yylen; |
| 1087 |
} |
| 1088 |
# endif |
| 1089 |
# endif |
| 1090 |
|
| 1091 |
# ifndef yystpcpy |
| 1092 |
# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE |
| 1093 |
# define yystpcpy stpcpy |
| 1094 |
# else |
| 1095 |
/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in |
| 1096 |
YYDEST. */ |
| 1097 |
static char * |
| 1098 |
yystpcpy (char *yydest, const char *yysrc) |
| 1099 |
{ |
| 1100 |
char *yyd = yydest; |
| 1101 |
const char *yys = yysrc; |
| 1102 |
|
| 1103 |
while ((*yyd++ = *yys++) != '\0') |
| 1104 |
continue; |
| 1105 |
|
| 1106 |
return yyd - 1; |
| 1107 |
} |
| 1108 |
# endif |
| 1109 |
# endif |
| 1110 |
|
| 1111 |
# ifndef yytnamerr |
| 1112 |
/* Copy to YYRES the contents of YYSTR after stripping away unnecessary |
| 1113 |
quotes and backslashes, so that it's suitable for yyerror. The |
| 1114 |
heuristic is that double-quoting is unnecessary unless the string |
| 1115 |
contains an apostrophe, a comma, or backslash (other than |
| 1116 |
backslash-backslash). YYSTR is taken from yytname. If YYRES is |
| 1117 |
null, do not copy; instead, return the length of what the result |
| 1118 |
would have been. */ |
| 1119 |
static YYSIZE_T |
| 1120 |
yytnamerr (char *yyres, const char *yystr) |
| 1121 |
{ |
| 1122 |
if (*yystr == '"') |
| 1123 |
{ |
| 1124 |
YYSIZE_T yyn = 0; |
| 1125 |
char const *yyp = yystr; |
| 1126 |
|
| 1127 |
for (;;) |
| 1128 |
switch (*++yyp) |
| 1129 |
{ |
| 1130 |
case '\'': |
| 1131 |
case ',': |
| 1132 |
goto do_not_strip_quotes; |
| 1133 |
|
| 1134 |
case '\\': |
| 1135 |
if (*++yyp != '\\') |
| 1136 |
goto do_not_strip_quotes; |
| 1137 |
/* Fall through. */ |
| 1138 |
default: |
| 1139 |
if (yyres) |
| 1140 |
yyres[yyn] = *yyp; |
| 1141 |
yyn++; |
| 1142 |
break; |
| 1143 |
|
| 1144 |
case '"': |
| 1145 |
if (yyres) |
| 1146 |
yyres[yyn] = '\0'; |
| 1147 |
return yyn; |
| 1148 |
} |
| 1149 |
do_not_strip_quotes: ; |
| 1150 |
} |
| 1151 |
|
| 1152 |
if (! yyres) |
| 1153 |
return yystrlen (yystr); |
| 1154 |
|
| 1155 |
return yystpcpy (yyres, yystr) - yyres; |
| 1156 |
} |
| 1157 |
# endif |
| 1158 |
|
| 1159 |
/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message |
| 1160 |
about the unexpected token YYTOKEN for the state stack whose top is |
| 1161 |
YYSSP. |
| 1162 |
|
| 1163 |
Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is |
| 1164 |
not large enough to hold the message. In that case, also set |
| 1165 |
*YYMSG_ALLOC to the required number of bytes. Return 2 if the |
| 1166 |
required number of bytes is too large to store. */ |
| 1167 |
static int |
| 1168 |
yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, |
| 1169 |
yytype_int16 *yyssp, int yytoken) |
| 1170 |
{ |
| 1171 |
YYSIZE_T yysize0 = yytnamerr (YY_NULLPTR, yytname[yytoken]); |
| 1172 |
YYSIZE_T yysize = yysize0; |
| 1173 |
enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; |
| 1174 |
/* Internationalized format string. */ |
| 1175 |
const char *yyformat = YY_NULLPTR; |
| 1176 |
/* Arguments of yyformat. */ |
| 1177 |
char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; |
| 1178 |
/* Number of reported tokens (one for the "unexpected", one per |
| 1179 |
"expected"). */ |
| 1180 |
int yycount = 0; |
| 1181 |
|
| 1182 |
/* There are many possibilities here to consider: |
| 1183 |
- If this state is a consistent state with a default action, then |
| 1184 |
the only way this function was invoked is if the default action |
| 1185 |
is an error action. In that case, don't check for expected |
| 1186 |
tokens because there are none. |
| 1187 |
- The only way there can be no lookahead present (in yychar) is if |
| 1188 |
this state is a consistent state with a default action. Thus, |
| 1189 |
detecting the absence of a lookahead is sufficient to determine |
| 1190 |
that there is no unexpected or expected token to report. In that |
| 1191 |
case, just report a simple "syntax error". |
| 1192 |
- Don't assume there isn't a lookahead just because this state is a |
| 1193 |
consistent state with a default action. There might have been a |
| 1194 |
previous inconsistent state, consistent state with a non-default |
| 1195 |
action, or user semantic action that manipulated yychar. |
| 1196 |
- Of course, the expected token list depends on states to have |
| 1197 |
correct lookahead information, and it depends on the parser not |
| 1198 |
to perform extra reductions after fetching a lookahead from the |
| 1199 |
scanner and before detecting a syntax error. Thus, state merging |
| 1200 |
(from LALR or IELR) and default reductions corrupt the expected |
| 1201 |
token list. However, the list is correct for canonical LR with |
| 1202 |
one exception: it will still contain any token that will not be |
| 1203 |
accepted due to an error action in a later state. |
| 1204 |
*/ |
| 1205 |
if (yytoken != YYEMPTY) |
| 1206 |
{ |
| 1207 |
int yyn = yypact[*yyssp]; |
| 1208 |
yyarg[yycount++] = yytname[yytoken]; |
| 1209 |
if (!yypact_value_is_default (yyn)) |
| 1210 |
{ |
| 1211 |
/* Start YYX at -YYN if negative to avoid negative indexes in |
| 1212 |
YYCHECK. In other words, skip the first -YYN actions for |
| 1213 |
this state because they are default actions. */ |
| 1214 |
int yyxbegin = yyn < 0 ? -yyn : 0; |
| 1215 |
/* Stay within bounds of both yycheck and yytname. */ |
| 1216 |
int yychecklim = YYLAST - yyn + 1; |
| 1217 |
int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; |
| 1218 |
int yyx; |
| 1219 |
|
| 1220 |
for (yyx = yyxbegin; yyx < yyxend; ++yyx) |
| 1221 |
if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR |
| 1222 |
&& !yytable_value_is_error (yytable[yyx + yyn])) |
| 1223 |
{ |
| 1224 |
if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) |
| 1225 |
{ |
| 1226 |
yycount = 1; |
| 1227 |
yysize = yysize0; |
| 1228 |
break; |
| 1229 |
} |
| 1230 |
yyarg[yycount++] = yytname[yyx]; |
| 1231 |
{ |
| 1232 |
YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULLPTR, yytname[yyx]); |
| 1233 |
if (! (yysize <= yysize1 |
| 1234 |
&& yysize1 <= YYSTACK_ALLOC_MAXIMUM)) |
| 1235 |
return 2; |
| 1236 |
yysize = yysize1; |
| 1237 |
} |
| 1238 |
} |
| 1239 |
} |
| 1240 |
} |
| 1241 |
|
| 1242 |
switch (yycount) |
| 1243 |
{ |
| 1244 |
# define YYCASE_(N, S) \ |
| 1245 |
case N: \ |
| 1246 |
yyformat = S; \ |
| 1247 |
break |
| 1248 |
YYCASE_(0, YY_("syntax error")); |
| 1249 |
YYCASE_(1, YY_("syntax error, unexpected %s")); |
| 1250 |
YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s")); |
| 1251 |
YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s")); |
| 1252 |
YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s")); |
| 1253 |
YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s")); |
| 1254 |
# undef YYCASE_ |
| 1255 |
} |
| 1256 |
|
| 1257 |
{ |
| 1258 |
YYSIZE_T yysize1 = yysize + yystrlen (yyformat); |
| 1259 |
if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) |
| 1260 |
return 2; |
| 1261 |
yysize = yysize1; |
| 1262 |
} |
| 1263 |
|
| 1264 |
if (*yymsg_alloc < yysize) |
| 1265 |
{ |
| 1266 |
*yymsg_alloc = 2 * yysize; |
| 1267 |
if (! (yysize <= *yymsg_alloc |
| 1268 |
&& *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM)) |
| 1269 |
*yymsg_alloc = YYSTACK_ALLOC_MAXIMUM; |
| 1270 |
return 1; |
| 1271 |
} |
| 1272 |
|
| 1273 |
/* Avoid sprintf, as that infringes on the user's name space. |
| 1274 |
Don't have undefined behavior even if the translation |
| 1275 |
produced a string with the wrong number of "%s"s. */ |
| 1276 |
{ |
| 1277 |
char *yyp = *yymsg; |
| 1278 |
int yyi = 0; |
| 1279 |
while ((*yyp = *yyformat) != '\0') |
| 1280 |
if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount) |
| 1281 |
{ |
| 1282 |
yyp += yytnamerr (yyp, yyarg[yyi++]); |
| 1283 |
yyformat += 2; |
| 1284 |
} |
| 1285 |
else |
| 1286 |
{ |
| 1287 |
yyp++; |
| 1288 |
yyformat++; |
| 1289 |
} |
| 1290 |
} |
| 1291 |
return 0; |
| 1292 |
} |
| 1293 |
#endif /* YYERROR_VERBOSE */ |
| 1294 |
|
| 1295 |
/*-----------------------------------------------. |
| 1296 |
| Release the memory associated to this symbol. | |
| 1297 |
`-----------------------------------------------*/ |
| 1298 |
|
| 1299 |
static void |
| 1300 |
yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep) |
| 1301 |
{ |
| 1302 |
YYUSE (yyvaluep); |
| 1303 |
if (!yymsg) |
| 1304 |
yymsg = "Deleting"; |
| 1305 |
YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); |
| 1306 |
|
| 1307 |
YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN |
| 1308 |
YYUSE (yytype); |
| 1309 |
YY_IGNORE_MAYBE_UNINITIALIZED_END |
| 1310 |
} |
| 1311 |
|
| 1312 |
|
| 1313 |
|
| 1314 |
|
| 1315 |
/* The lookahead symbol. */ |
| 1316 |
int yychar; |
| 1317 |
|
| 1318 |
/* The semantic value of the lookahead symbol. */ |
| 1319 |
YYSTYPE yylval; |
| 1320 |
/* Number of syntax errors so far. */ |
| 1321 |
int yynerrs; |
| 1322 |
|
| 1323 |
|
| 1324 |
/*----------. |
| 1325 |
| yyparse. | |
| 1326 |
`----------*/ |
| 1327 |
|
| 1328 |
int |
| 1329 |
yyparse (void) |
| 1330 |
{ |
| 1331 |
int yystate; |
| 1332 |
/* Number of tokens to shift before error messages enabled. */ |
| 1333 |
int yyerrstatus; |
| 1334 |
|
| 1335 |
/* The stacks and their tools: |
| 1336 |
'yyss': related to states. |
| 1337 |
'yyvs': related to semantic values. |
| 1338 |
|
| 1339 |
Refer to the stacks through separate pointers, to allow yyoverflow |
| 1340 |
to reallocate them elsewhere. */ |
| 1341 |
|
| 1342 |
/* The state stack. */ |
| 1343 |
yytype_int16 yyssa[YYINITDEPTH]; |
| 1344 |
yytype_int16 *yyss; |
| 1345 |
yytype_int16 *yyssp; |
| 1346 |
|
| 1347 |
/* The semantic value stack. */ |
| 1348 |
YYSTYPE yyvsa[YYINITDEPTH]; |
| 1349 |
YYSTYPE *yyvs; |
| 1350 |
YYSTYPE *yyvsp; |
| 1351 |
|
| 1352 |
YYSIZE_T yystacksize; |
| 1353 |
|
| 1354 |
int yyn; |
| 1355 |
int yyresult; |
| 1356 |
/* Lookahead token as an internal (translated) token number. */ |
| 1357 |
int yytoken = 0; |
| 1358 |
/* The variables used to return semantic value and location from the |
| 1359 |
action routines. */ |
| 1360 |
YYSTYPE yyval; |
| 1361 |
|
| 1362 |
#if YYERROR_VERBOSE |
| 1363 |
/* Buffer for error messages, and its allocated size. */ |
| 1364 |
char yymsgbuf[128]; |
| 1365 |
char *yymsg = yymsgbuf; |
| 1366 |
YYSIZE_T yymsg_alloc = sizeof yymsgbuf; |
| 1367 |
#endif |
| 1368 |
|
| 1369 |
#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) |
| 1370 |
|
| 1371 |
/* The number of symbols on the RHS of the reduced rule. |
| 1372 |
Keep to zero when no symbol should be popped. */ |
| 1373 |
int yylen = 0; |
| 1374 |
|
| 1375 |
yyssp = yyss = yyssa; |
| 1376 |
yyvsp = yyvs = yyvsa; |
| 1377 |
yystacksize = YYINITDEPTH; |
| 1378 |
|
| 1379 |
YYDPRINTF ((stderr, "Starting parse\n")); |
| 1380 |
|
| 1381 |
yystate = 0; |
| 1382 |
yyerrstatus = 0; |
| 1383 |
yynerrs = 0; |
| 1384 |
yychar = YYEMPTY; /* Cause a token to be read. */ |
| 1385 |
goto yysetstate; |
| 1386 |
|
| 1387 |
/*------------------------------------------------------------. |
| 1388 |
| yynewstate -- Push a new state, which is found in yystate. | |
| 1389 |
`------------------------------------------------------------*/ |
| 1390 |
yynewstate: |
| 1391 |
/* In all cases, when you get here, the value and location stacks |
| 1392 |
have just been pushed. So pushing a state here evens the stacks. */ |
| 1393 |
yyssp++; |
| 1394 |
|
| 1395 |
yysetstate: |
| 1396 |
*yyssp = yystate; |
| 1397 |
|
| 1398 |
if (yyss + yystacksize - 1 <= yyssp) |
| 1399 |
{ |
| 1400 |
/* Get the current used size of the three stacks, in elements. */ |
| 1401 |
YYSIZE_T yysize = yyssp - yyss + 1; |
| 1402 |
|
| 1403 |
#ifdef yyoverflow |
| 1404 |
{ |
| 1405 |
/* Give user a chance to reallocate the stack. Use copies of |
| 1406 |
these so that the &'s don't force the real ones into |
| 1407 |
memory. */ |
| 1408 |
YYSTYPE *yyvs1 = yyvs; |
| 1409 |
yytype_int16 *yyss1 = yyss; |
| 1410 |
|
| 1411 |
/* Each stack pointer address is followed by the size of the |
| 1412 |
data in use in that stack, in bytes. This used to be a |
| 1413 |
conditional around just the two extra args, but that might |
| 1414 |
be undefined if yyoverflow is a macro. */ |
| 1415 |
yyoverflow (YY_("memory exhausted"), |
| 1416 |
&yyss1, yysize * sizeof (*yyssp), |
| 1417 |
&yyvs1, yysize * sizeof (*yyvsp), |
| 1418 |
&yystacksize); |
| 1419 |
|
| 1420 |
yyss = yyss1; |
| 1421 |
yyvs = yyvs1; |
| 1422 |
} |
| 1423 |
#else /* no yyoverflow */ |
| 1424 |
# ifndef YYSTACK_RELOCATE |
| 1425 |
goto yyexhaustedlab; |
| 1426 |
# else |
| 1427 |
/* Extend the stack our own way. */ |
| 1428 |
if (YYMAXDEPTH <= yystacksize) |
| 1429 |
goto yyexhaustedlab; |
| 1430 |
yystacksize *= 2; |
| 1431 |
if (YYMAXDEPTH < yystacksize) |
| 1432 |
yystacksize = YYMAXDEPTH; |
| 1433 |
|
| 1434 |
{ |
| 1435 |
yytype_int16 *yyss1 = yyss; |
| 1436 |
union yyalloc *yyptr = |
| 1437 |
(union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); |
| 1438 |
if (! yyptr) |
| 1439 |
goto yyexhaustedlab; |
| 1440 |
YYSTACK_RELOCATE (yyss_alloc, yyss); |
| 1441 |
YYSTACK_RELOCATE (yyvs_alloc, yyvs); |
| 1442 |
# undef YYSTACK_RELOCATE |
| 1443 |
if (yyss1 != yyssa) |
| 1444 |
YYSTACK_FREE (yyss1); |
| 1445 |
} |
| 1446 |
# endif |
| 1447 |
#endif /* no yyoverflow */ |
| 1448 |
|
| 1449 |
yyssp = yyss + yysize - 1; |
| 1450 |
yyvsp = yyvs + yysize - 1; |
| 1451 |
|
| 1452 |
YYDPRINTF ((stderr, "Stack size increased to %lu\n", |
| 1453 |
(unsigned long int) yystacksize)); |
| 1454 |
|
| 1455 |
if (yyss + yystacksize - 1 <= yyssp) |
| 1456 |
YYABORT; |
| 1457 |
} |
| 1458 |
|
| 1459 |
YYDPRINTF ((stderr, "Entering state %d\n", yystate)); |
| 1460 |
|
| 1461 |
if (yystate == YYFINAL) |
| 1462 |
YYACCEPT; |
| 1463 |
|
| 1464 |
goto yybackup; |
| 1465 |
|
| 1466 |
/*-----------. |
| 1467 |
| yybackup. | |
| 1468 |
`-----------*/ |
| 1469 |
yybackup: |
| 1470 |
|
| 1471 |
/* Do appropriate processing given the current state. Read a |
| 1472 |
lookahead token if we need one and don't already have one. */ |
| 1473 |
|
| 1474 |
/* First try to decide what to do without reference to lookahead token. */ |
| 1475 |
yyn = yypact[yystate]; |
| 1476 |
if (yypact_value_is_default (yyn)) |
| 1477 |
goto yydefault; |
| 1478 |
|
| 1479 |
/* Not known => get a lookahead token if don't already have one. */ |
| 1480 |
|
| 1481 |
/* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */ |
| 1482 |
if (yychar == YYEMPTY) |
| 1483 |
{ |
| 1484 |
YYDPRINTF ((stderr, "Reading a token: ")); |
| 1485 |
yychar = yylex (); |
| 1486 |
} |
| 1487 |
|
| 1488 |
if (yychar <= YYEOF) |
| 1489 |
{ |
| 1490 |
yychar = yytoken = YYEOF; |
| 1491 |
YYDPRINTF ((stderr, "Now at end of input.\n")); |
| 1492 |
} |
| 1493 |
else |
| 1494 |
{ |
| 1495 |
yytoken = YYTRANSLATE (yychar); |
| 1496 |
YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); |
| 1497 |
} |
| 1498 |
|
| 1499 |
/* If the proper action on seeing token YYTOKEN is to reduce or to |
| 1500 |
detect an error, take that action. */ |
| 1501 |
yyn += yytoken; |
| 1502 |
if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) |
| 1503 |
goto yydefault; |
| 1504 |
yyn = yytable[yyn]; |
| 1505 |
if (yyn <= 0) |
| 1506 |
{ |
| 1507 |
if (yytable_value_is_error (yyn)) |
| 1508 |
goto yyerrlab; |
| 1509 |
yyn = -yyn; |
| 1510 |
goto yyreduce; |
| 1511 |
} |
| 1512 |
|
| 1513 |
/* Count tokens shifted since error; after three, turn off error |
| 1514 |
status. */ |
| 1515 |
if (yyerrstatus) |
| 1516 |
yyerrstatus--; |
| 1517 |
|
| 1518 |
/* Shift the lookahead token. */ |
| 1519 |
YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); |
| 1520 |
|
| 1521 |
/* Discard the shifted token. */ |
| 1522 |
yychar = YYEMPTY; |
| 1523 |
|
| 1524 |
yystate = yyn; |
| 1525 |
YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN |
| 1526 |
*++yyvsp = yylval; |
| 1527 |
YY_IGNORE_MAYBE_UNINITIALIZED_END |
| 1528 |
|
| 1529 |
goto yynewstate; |
| 1530 |
|
| 1531 |
|
| 1532 |
/*-----------------------------------------------------------. |
| 1533 |
| yydefault -- do the default action for the current state. | |
| 1534 |
`-----------------------------------------------------------*/ |
| 1535 |
yydefault: |
| 1536 |
yyn = yydefact[yystate]; |
| 1537 |
if (yyn == 0) |
| 1538 |
goto yyerrlab; |
| 1539 |
goto yyreduce; |
| 1540 |
|
| 1541 |
|
| 1542 |
/*-----------------------------. |
| 1543 |
| yyreduce -- Do a reduction. | |
| 1544 |
`-----------------------------*/ |
| 1545 |
yyreduce: |
| 1546 |
/* yyn is the number of a rule to reduce with. */ |
| 1547 |
yylen = yyr2[yyn]; |
| 1548 |
|
| 1549 |
/* If YYLEN is nonzero, implement the default value of the action: |
| 1550 |
'$$ = $1'. |
| 1551 |
|
| 1552 |
Otherwise, the following line sets YYVAL to garbage. |
| 1553 |
This behavior is undocumented and Bison |
| 1554 |
users should not rely upon it. Assigning to YYVAL |
| 1555 |
unconditionally makes the parser a bit smaller, and it avoids a |
| 1556 |
GCC warning that YYVAL may be used uninitialized. */ |
| 1557 |
yyval = yyvsp[1-yylen]; |
| 1558 |
|
| 1559 |
|
| 1560 |
YY_REDUCE_PRINT (yyn); |
| 1561 |
switch (yyn) |
| 1562 |
{ |
| 1563 |
case 10: |
| 1564 |
#line 111 "config-parser.y" /* yacc.c:1646 */ |
| 1565 |
{ (yyval.number) = 0; } |
| 1566 |
#line 1567 "config-parser.c" /* yacc.c:1646 */ |
| 1567 |
break; |
| 1568 |
|
| 1569 |
case 12: |
| 1570 |
#line 112 "config-parser.y" /* yacc.c:1646 */ |
| 1571 |
{ (yyval.number) = (yyvsp[-1].number) + (yyvsp[0].number); } |
| 1572 |
#line 1573 "config-parser.c" /* yacc.c:1646 */ |
| 1573 |
break; |
| 1574 |
|
| 1575 |
case 13: |
| 1576 |
#line 113 "config-parser.y" /* yacc.c:1646 */ |
| 1577 |
{ (yyval.number) = (yyvsp[-2].number) + (yyvsp[0].number); } |
| 1578 |
#line 1579 "config-parser.c" /* yacc.c:1646 */ |
| 1579 |
break; |
| 1580 |
|
| 1581 |
case 14: |
| 1582 |
#line 114 "config-parser.y" /* yacc.c:1646 */ |
| 1583 |
{ (yyval.number) = (yyvsp[-2].number) * 60 + (yyvsp[0].number); } |
| 1584 |
#line 1585 "config-parser.c" /* yacc.c:1646 */ |
| 1585 |
break; |
| 1586 |
|
| 1587 |
case 15: |
| 1588 |
#line 115 "config-parser.y" /* yacc.c:1646 */ |
| 1589 |
{ (yyval.number) = (yyvsp[-2].number) * 60 * 60 + (yyvsp[0].number); } |
| 1590 |
#line 1591 "config-parser.c" /* yacc.c:1646 */ |
| 1591 |
break; |
| 1592 |
|
| 1593 |
case 16: |
| 1594 |
#line 116 "config-parser.y" /* yacc.c:1646 */ |
| 1595 |
{ (yyval.number) = (yyvsp[-2].number) * 60 * 60 * 24 + (yyvsp[0].number); } |
| 1596 |
#line 1597 "config-parser.c" /* yacc.c:1646 */ |
| 1597 |
break; |
| 1598 |
|
| 1599 |
case 17: |
| 1600 |
#line 117 "config-parser.y" /* yacc.c:1646 */ |
| 1601 |
{ (yyval.number) = (yyvsp[-2].number) * 60 * 60 * 24 * 7 + (yyvsp[0].number); } |
| 1602 |
#line 1603 "config-parser.c" /* yacc.c:1646 */ |
| 1603 |
break; |
| 1604 |
|
| 1605 |
case 18: |
| 1606 |
#line 118 "config-parser.y" /* yacc.c:1646 */ |
| 1607 |
{ (yyval.number) = (yyvsp[-2].number) * 60 * 60 * 24 * 7 * 4 + (yyvsp[0].number); } |
| 1608 |
#line 1609 "config-parser.c" /* yacc.c:1646 */ |
| 1609 |
break; |
| 1610 |
|
| 1611 |
case 19: |
| 1612 |
#line 119 "config-parser.y" /* yacc.c:1646 */ |
| 1613 |
{ (yyval.number) = (yyvsp[-2].number) * 60 * 60 * 24 * 365 + (yyvsp[0].number); } |
| 1614 |
#line 1615 "config-parser.c" /* yacc.c:1646 */ |
| 1615 |
break; |
| 1616 |
|
| 1617 |
case 20: |
| 1618 |
#line 122 "config-parser.y" /* yacc.c:1646 */ |
| 1619 |
{ (yyval.number) = 0; } |
| 1620 |
#line 1621 "config-parser.c" /* yacc.c:1646 */ |
| 1621 |
break; |
| 1622 |
|
| 1623 |
case 22: |
| 1624 |
#line 123 "config-parser.y" /* yacc.c:1646 */ |
| 1625 |
{ (yyval.number) = (yyvsp[-1].number) + (yyvsp[0].number); } |
| 1626 |
#line 1627 "config-parser.c" /* yacc.c:1646 */ |
| 1627 |
break; |
| 1628 |
|
| 1629 |
case 23: |
| 1630 |
#line 124 "config-parser.y" /* yacc.c:1646 */ |
| 1631 |
{ (yyval.number) = (yyvsp[-2].number) + (yyvsp[0].number); } |
| 1632 |
#line 1633 "config-parser.c" /* yacc.c:1646 */ |
| 1633 |
break; |
| 1634 |
|
| 1635 |
case 24: |
| 1636 |
#line 125 "config-parser.y" /* yacc.c:1646 */ |
| 1637 |
{ (yyval.number) = (yyvsp[-2].number) * 1024 + (yyvsp[0].number); } |
| 1638 |
#line 1639 "config-parser.c" /* yacc.c:1646 */ |
| 1639 |
break; |
| 1640 |
|
| 1641 |
case 25: |
| 1642 |
#line 126 "config-parser.y" /* yacc.c:1646 */ |
| 1643 |
{ (yyval.number) = (yyvsp[-2].number) * 1024 * 1024 + (yyvsp[0].number); } |
| 1644 |
#line 1645 "config-parser.c" /* yacc.c:1646 */ |
| 1645 |
break; |
| 1646 |
|
| 1647 |
case 34: |
| 1648 |
#line 143 "config-parser.y" /* yacc.c:1646 */ |
| 1649 |
{ |
| 1650 |
OptionsItem->negcache = (yyvsp[-1].number); |
| 1651 |
} |
| 1652 |
#line 1653 "config-parser.c" /* yacc.c:1646 */ |
| 1653 |
break; |
| 1654 |
|
| 1655 |
case 35: |
| 1656 |
#line 148 "config-parser.y" /* yacc.c:1646 */ |
| 1657 |
{ |
| 1658 |
MyFree(OptionsItem->pidfile); |
| 1659 |
OptionsItem->pidfile = xstrdup((yyvsp[-1].string)); |
| 1660 |
} |
| 1661 |
#line 1662 "config-parser.c" /* yacc.c:1646 */ |
| 1662 |
break; |
| 1663 |
|
| 1664 |
case 36: |
| 1665 |
#line 154 "config-parser.y" /* yacc.c:1646 */ |
| 1666 |
{ |
| 1667 |
OptionsItem->dns_fdlimit = (yyvsp[-1].number); |
| 1668 |
} |
| 1669 |
#line 1670 "config-parser.c" /* yacc.c:1646 */ |
| 1670 |
break; |
| 1671 |
|
| 1672 |
case 37: |
| 1673 |
#line 159 "config-parser.y" /* yacc.c:1646 */ |
| 1674 |
{ |
| 1675 |
MyFree(OptionsItem->scanlog); |
| 1676 |
OptionsItem->scanlog = xstrdup((yyvsp[-1].string)); |
| 1677 |
} |
| 1678 |
#line 1679 "config-parser.c" /* yacc.c:1646 */ |
| 1679 |
break; |
| 1680 |
|
| 1681 |
case 57: |
| 1682 |
#line 189 "config-parser.y" /* yacc.c:1646 */ |
| 1683 |
{ |
| 1684 |
MyFree(IRCItem->away); |
| 1685 |
IRCItem->away = xstrdup((yyvsp[-1].string)); |
| 1686 |
} |
| 1687 |
#line 1688 "config-parser.c" /* yacc.c:1646 */ |
| 1688 |
break; |
| 1689 |
|
| 1690 |
case 58: |
| 1691 |
#line 195 "config-parser.y" /* yacc.c:1646 */ |
| 1692 |
{ |
| 1693 |
MyFree(IRCItem->kline); |
| 1694 |
IRCItem->kline = xstrdup((yyvsp[-1].string)); |
| 1695 |
} |
| 1696 |
#line 1697 "config-parser.c" /* yacc.c:1646 */ |
| 1697 |
break; |
| 1698 |
|
| 1699 |
case 59: |
| 1700 |
#line 201 "config-parser.y" /* yacc.c:1646 */ |
| 1701 |
{ |
| 1702 |
MyFree(IRCItem->mode); |
| 1703 |
IRCItem->mode = xstrdup((yyvsp[-1].string)); |
| 1704 |
} |
| 1705 |
#line 1706 "config-parser.c" /* yacc.c:1646 */ |
| 1706 |
break; |
| 1707 |
|
| 1708 |
case 60: |
| 1709 |
#line 207 "config-parser.y" /* yacc.c:1646 */ |
| 1710 |
{ |
| 1711 |
MyFree(IRCItem->nick); |
| 1712 |
IRCItem->nick = xstrdup((yyvsp[-1].string)); |
| 1713 |
} |
| 1714 |
#line 1715 "config-parser.c" /* yacc.c:1646 */ |
| 1715 |
break; |
| 1716 |
|
| 1717 |
case 61: |
| 1718 |
#line 213 "config-parser.y" /* yacc.c:1646 */ |
| 1719 |
{ |
| 1720 |
MyFree(IRCItem->nickserv); |
| 1721 |
IRCItem->nickserv = xstrdup((yyvsp[-1].string)); |
| 1722 |
} |
| 1723 |
#line 1724 "config-parser.c" /* yacc.c:1646 */ |
| 1724 |
break; |
| 1725 |
|
| 1726 |
case 62: |
| 1727 |
#line 219 "config-parser.y" /* yacc.c:1646 */ |
| 1728 |
{ |
| 1729 |
MyFree(IRCItem->oper); |
| 1730 |
IRCItem->oper = xstrdup((yyvsp[-1].string)); |
| 1731 |
} |
| 1732 |
#line 1733 "config-parser.c" /* yacc.c:1646 */ |
| 1733 |
break; |
| 1734 |
|
| 1735 |
case 63: |
| 1736 |
#line 225 "config-parser.y" /* yacc.c:1646 */ |
| 1737 |
{ |
| 1738 |
MyFree(IRCItem->password); |
| 1739 |
IRCItem->password = xstrdup((yyvsp[-1].string)); |
| 1740 |
} |
| 1741 |
#line 1742 "config-parser.c" /* yacc.c:1646 */ |
| 1742 |
break; |
| 1743 |
|
| 1744 |
case 64: |
| 1745 |
#line 231 "config-parser.y" /* yacc.c:1646 */ |
| 1746 |
{ |
| 1747 |
node_t *node; |
| 1748 |
node = node_create(xstrdup((yyvsp[-1].string))); |
| 1749 |
|
| 1750 |
list_add(IRCItem->performs, node); |
| 1751 |
} |
| 1752 |
#line 1753 "config-parser.c" /* yacc.c:1646 */ |
| 1753 |
break; |
| 1754 |
|
| 1755 |
case 65: |
| 1756 |
#line 239 "config-parser.y" /* yacc.c:1646 */ |
| 1757 |
{ |
| 1758 |
IRCItem->port = (yyvsp[-1].number); |
| 1759 |
} |
| 1760 |
#line 1761 "config-parser.c" /* yacc.c:1646 */ |
| 1761 |
break; |
| 1762 |
|
| 1763 |
case 66: |
| 1764 |
#line 244 "config-parser.y" /* yacc.c:1646 */ |
| 1765 |
{ |
| 1766 |
MyFree(IRCItem->realname); |
| 1767 |
IRCItem->realname = xstrdup((yyvsp[-1].string)); |
| 1768 |
} |
| 1769 |
#line 1770 "config-parser.c" /* yacc.c:1646 */ |
| 1770 |
break; |
| 1771 |
|
| 1772 |
case 67: |
| 1773 |
#line 250 "config-parser.y" /* yacc.c:1646 */ |
| 1774 |
{ |
| 1775 |
MyFree(IRCItem->server); |
| 1776 |
IRCItem->server = xstrdup((yyvsp[-1].string)); |
| 1777 |
} |
| 1778 |
#line 1779 "config-parser.c" /* yacc.c:1646 */ |
| 1779 |
break; |
| 1780 |
|
| 1781 |
case 68: |
| 1782 |
#line 256 "config-parser.y" /* yacc.c:1646 */ |
| 1783 |
{ |
| 1784 |
MyFree(IRCItem->username); |
| 1785 |
IRCItem->username = xstrdup((yyvsp[-1].string)); |
| 1786 |
} |
| 1787 |
#line 1788 "config-parser.c" /* yacc.c:1646 */ |
| 1788 |
break; |
| 1789 |
|
| 1790 |
case 69: |
| 1791 |
#line 262 "config-parser.y" /* yacc.c:1646 */ |
| 1792 |
{ |
| 1793 |
MyFree(IRCItem->vhost); |
| 1794 |
IRCItem->vhost = xstrdup((yyvsp[-1].string)); |
| 1795 |
} |
| 1796 |
#line 1797 "config-parser.c" /* yacc.c:1646 */ |
| 1797 |
break; |
| 1798 |
|
| 1799 |
case 70: |
| 1800 |
#line 268 "config-parser.y" /* yacc.c:1646 */ |
| 1801 |
{ |
| 1802 |
MyFree(IRCItem->connregex); |
| 1803 |
IRCItem->connregex = xstrdup((yyvsp[-1].string)); |
| 1804 |
} |
| 1805 |
#line 1806 "config-parser.c" /* yacc.c:1646 */ |
| 1806 |
break; |
| 1807 |
|
| 1808 |
case 71: |
| 1809 |
#line 277 "config-parser.y" /* yacc.c:1646 */ |
| 1810 |
{ |
| 1811 |
node_t *node; |
| 1812 |
struct ChannelConf *item; |
| 1813 |
|
| 1814 |
item = MyMalloc(sizeof *item); |
| 1815 |
|
| 1816 |
item->name = xstrdup(""); |
| 1817 |
item->key = xstrdup(""); |
| 1818 |
item->invite = xstrdup(""); |
| 1819 |
|
| 1820 |
node = node_create(item); |
| 1821 |
list_add(IRCItem->channels, node); |
| 1822 |
|
| 1823 |
tmp = (void *) item; |
| 1824 |
} |
| 1825 |
#line 1826 "config-parser.c" /* yacc.c:1646 */ |
| 1826 |
break; |
| 1827 |
|
| 1828 |
case 78: |
| 1829 |
#line 302 "config-parser.y" /* yacc.c:1646 */ |
| 1830 |
{ |
| 1831 |
struct ChannelConf *item = tmp; |
| 1832 |
|
| 1833 |
MyFree(item->name); |
| 1834 |
item->name = xstrdup((yyvsp[-1].string)); |
| 1835 |
} |
| 1836 |
#line 1837 "config-parser.c" /* yacc.c:1646 */ |
| 1837 |
break; |
| 1838 |
|
| 1839 |
case 79: |
| 1840 |
#line 310 "config-parser.y" /* yacc.c:1646 */ |
| 1841 |
{ |
| 1842 |
struct ChannelConf *item = tmp; |
| 1843 |
|
| 1844 |
MyFree(item->key); |
| 1845 |
item->key = xstrdup((yyvsp[-1].string)); |
| 1846 |
} |
| 1847 |
#line 1848 "config-parser.c" /* yacc.c:1646 */ |
| 1848 |
break; |
| 1849 |
|
| 1850 |
case 80: |
| 1851 |
#line 318 "config-parser.y" /* yacc.c:1646 */ |
| 1852 |
{ |
| 1853 |
struct ChannelConf *item = tmp; |
| 1854 |
|
| 1855 |
MyFree(item->invite); |
| 1856 |
item->invite = xstrdup((yyvsp[-1].string)); |
| 1857 |
} |
| 1858 |
#line 1859 "config-parser.c" /* yacc.c:1646 */ |
| 1859 |
break; |
| 1860 |
|
| 1861 |
case 81: |
| 1862 |
#line 328 "config-parser.y" /* yacc.c:1646 */ |
| 1863 |
{ |
| 1864 |
node_t *node; |
| 1865 |
struct UserConf *item; |
| 1866 |
|
| 1867 |
item = MyMalloc(sizeof *item); |
| 1868 |
|
| 1869 |
item->masks = list_create(); |
| 1870 |
item->scanners = list_create(); |
| 1871 |
|
| 1872 |
node = node_create(item); |
| 1873 |
list_add(UserItemList, node); |
| 1874 |
|
| 1875 |
tmp = (void *) item; |
| 1876 |
} |
| 1877 |
#line 1878 "config-parser.c" /* yacc.c:1646 */ |
| 1878 |
break; |
| 1879 |
|
| 1880 |
case 88: |
| 1881 |
#line 352 "config-parser.y" /* yacc.c:1646 */ |
| 1882 |
{ |
| 1883 |
struct UserConf *item = (struct UserConf *) tmp; |
| 1884 |
|
| 1885 |
node_t *node; |
| 1886 |
node = node_create((void *) xstrdup((yyvsp[-1].string))); |
| 1887 |
|
| 1888 |
list_add(item->masks, node); |
| 1889 |
} |
| 1890 |
#line 1891 "config-parser.c" /* yacc.c:1646 */ |
| 1891 |
break; |
| 1892 |
|
| 1893 |
case 89: |
| 1894 |
#line 362 "config-parser.y" /* yacc.c:1646 */ |
| 1895 |
{ |
| 1896 |
struct UserConf *item = (struct UserConf *) tmp; |
| 1897 |
|
| 1898 |
node_t *node; |
| 1899 |
node = node_create((void *) xstrdup((yyvsp[-1].string))); |
| 1900 |
|
| 1901 |
list_add(item->scanners, node); |
| 1902 |
} |
| 1903 |
#line 1904 "config-parser.c" /* yacc.c:1646 */ |
| 1904 |
break; |
| 1905 |
|
| 1906 |
case 90: |
| 1907 |
#line 374 "config-parser.y" /* yacc.c:1646 */ |
| 1908 |
{ |
| 1909 |
node_t *node; |
| 1910 |
struct ScannerConf *item, *olditem; |
| 1911 |
|
| 1912 |
item = MyMalloc(sizeof *item); |
| 1913 |
|
| 1914 |
/* Setup ScannerConf defaults */ |
| 1915 |
item->name = xstrdup("undefined"); |
| 1916 |
|
| 1917 |
if(LIST_SIZE(ScannerItemList) > 0) |
| 1918 |
{ |
| 1919 |
olditem = ScannerItemList->tail->data; |
| 1920 |
|
| 1921 |
item->vhost = xstrdup(olditem->vhost); |
| 1922 |
item->fd = olditem->fd; |
| 1923 |
item->target_ip = xstrdup(olditem->target_ip); |
| 1924 |
item->target_port = olditem->target_port; |
| 1925 |
item->timeout = olditem->timeout; |
| 1926 |
item->max_read = olditem->max_read; |
| 1927 |
|
| 1928 |
item->target_string = olditem->target_string; |
| 1929 |
item->target_string_created = 0; |
| 1930 |
} |
| 1931 |
else |
| 1932 |
{ |
| 1933 |
item->vhost = xstrdup("0.0.0.0"); |
| 1934 |
item->fd = 512; |
| 1935 |
item->target_ip = xstrdup("127.0.0.1"); |
| 1936 |
item->target_port = 6667; |
| 1937 |
item->timeout = 30; |
| 1938 |
item->max_read = 4096; |
| 1939 |
|
| 1940 |
item->target_string = list_create(); |
| 1941 |
item->target_string_created = 1; |
| 1942 |
} |
| 1943 |
|
| 1944 |
item->protocols = list_create(); |
| 1945 |
|
| 1946 |
node = node_create(item); |
| 1947 |
|
| 1948 |
list_add(ScannerItemList, node); |
| 1949 |
tmp = (void *) item; |
| 1950 |
} |
| 1951 |
#line 1952 "config-parser.c" /* yacc.c:1646 */ |
| 1952 |
break; |
| 1953 |
|
| 1954 |
case 104: |
| 1955 |
#line 434 "config-parser.y" /* yacc.c:1646 */ |
| 1956 |
{ |
| 1957 |
struct ScannerConf *item = (struct ScannerConf *) tmp; |
| 1958 |
MyFree(item->name); |
| 1959 |
item->name = xstrdup((yyvsp[-1].string)); |
| 1960 |
} |
| 1961 |
#line 1962 "config-parser.c" /* yacc.c:1646 */ |
| 1962 |
break; |
| 1963 |
|
| 1964 |
case 105: |
| 1965 |
#line 441 "config-parser.y" /* yacc.c:1646 */ |
| 1966 |
{ |
| 1967 |
struct ScannerConf *item = (struct ScannerConf *) tmp; |
| 1968 |
MyFree(item->vhost); |
| 1969 |
item->vhost = xstrdup((yyvsp[-1].string)); |
| 1970 |
} |
| 1971 |
#line 1972 "config-parser.c" /* yacc.c:1646 */ |
| 1972 |
break; |
| 1973 |
|
| 1974 |
case 106: |
| 1975 |
#line 448 "config-parser.y" /* yacc.c:1646 */ |
| 1976 |
{ |
| 1977 |
struct ScannerConf *item = (struct ScannerConf *) tmp; |
| 1978 |
MyFree(item->target_ip); |
| 1979 |
item->target_ip = xstrdup((yyvsp[-1].string)); |
| 1980 |
} |
| 1981 |
#line 1982 "config-parser.c" /* yacc.c:1646 */ |
| 1982 |
break; |
| 1983 |
|
| 1984 |
case 107: |
| 1985 |
#line 455 "config-parser.y" /* yacc.c:1646 */ |
| 1986 |
{ |
| 1987 |
struct ScannerConf *item = (struct ScannerConf *) tmp; |
| 1988 |
|
| 1989 |
node_t *node; |
| 1990 |
node = node_create((yyvsp[-1].string)); |
| 1991 |
|
| 1992 |
if(item->target_string_created == 0) |
| 1993 |
{ |
| 1994 |
item->target_string = list_create(); |
| 1995 |
item->target_string_created = 1; |
| 1996 |
} |
| 1997 |
|
| 1998 |
list_add(item->target_string, node); |
| 1999 |
} |
| 2000 |
#line 2001 "config-parser.c" /* yacc.c:1646 */ |
| 2001 |
break; |
| 2002 |
|
| 2003 |
case 108: |
| 2004 |
#line 471 "config-parser.y" /* yacc.c:1646 */ |
| 2005 |
{ |
| 2006 |
struct ScannerConf *item = (struct ScannerConf *) tmp; |
| 2007 |
item->fd = (yyvsp[-1].number); |
| 2008 |
} |
| 2009 |
#line 2010 "config-parser.c" /* yacc.c:1646 */ |
| 2010 |
break; |
| 2011 |
|
| 2012 |
case 109: |
| 2013 |
#line 477 "config-parser.y" /* yacc.c:1646 */ |
| 2014 |
{ |
| 2015 |
struct ScannerConf *item = (struct ScannerConf *) tmp; |
| 2016 |
item->target_port = (yyvsp[-1].number); |
| 2017 |
} |
| 2018 |
#line 2019 "config-parser.c" /* yacc.c:1646 */ |
| 2019 |
break; |
| 2020 |
|
| 2021 |
case 110: |
| 2022 |
#line 483 "config-parser.y" /* yacc.c:1646 */ |
| 2023 |
{ |
| 2024 |
struct ScannerConf *item = (struct ScannerConf *) tmp; |
| 2025 |
item->timeout = (yyvsp[-1].number); |
| 2026 |
} |
| 2027 |
#line 2028 "config-parser.c" /* yacc.c:1646 */ |
| 2028 |
break; |
| 2029 |
|
| 2030 |
case 111: |
| 2031 |
#line 489 "config-parser.y" /* yacc.c:1646 */ |
| 2032 |
{ |
| 2033 |
struct ScannerConf *item = (struct ScannerConf *) tmp; |
| 2034 |
item->max_read = (yyvsp[-1].number); |
| 2035 |
} |
| 2036 |
#line 2037 "config-parser.c" /* yacc.c:1646 */ |
| 2037 |
break; |
| 2038 |
|
| 2039 |
case 112: |
| 2040 |
#line 495 "config-parser.y" /* yacc.c:1646 */ |
| 2041 |
{ |
| 2042 |
struct ProtocolConf *item; |
| 2043 |
struct ScannerConf *item2; |
| 2044 |
|
| 2045 |
node_t *node; |
| 2046 |
|
| 2047 |
item = MyMalloc(sizeof *item); |
| 2048 |
item->type = (yyvsp[-3].number); |
| 2049 |
item->port = (yyvsp[-1].number); |
| 2050 |
|
| 2051 |
item2 = (struct ScannerConf *) tmp; |
| 2052 |
|
| 2053 |
node = node_create(item); |
| 2054 |
list_add(item2->protocols, node); |
| 2055 |
} |
| 2056 |
#line 2057 "config-parser.c" /* yacc.c:1646 */ |
| 2057 |
break; |
| 2058 |
|
| 2059 |
case 121: |
| 2060 |
#line 525 "config-parser.y" /* yacc.c:1646 */ |
| 2061 |
{ |
| 2062 |
MyFree(OpmItem->dnsbl_from); |
| 2063 |
OpmItem->dnsbl_from = xstrdup((yyvsp[-1].string)); |
| 2064 |
} |
| 2065 |
#line 2066 "config-parser.c" /* yacc.c:1646 */ |
| 2066 |
break; |
| 2067 |
|
| 2068 |
case 122: |
| 2069 |
#line 531 "config-parser.y" /* yacc.c:1646 */ |
| 2070 |
{ |
| 2071 |
MyFree(OpmItem->dnsbl_to); |
| 2072 |
OpmItem->dnsbl_to = xstrdup((yyvsp[-1].string)); |
| 2073 |
} |
| 2074 |
#line 2075 "config-parser.c" /* yacc.c:1646 */ |
| 2075 |
break; |
| 2076 |
|
| 2077 |
case 123: |
| 2078 |
#line 537 "config-parser.y" /* yacc.c:1646 */ |
| 2079 |
{ |
| 2080 |
MyFree(OpmItem->sendmail); |
| 2081 |
OpmItem->sendmail = xstrdup((yyvsp[-1].string)); |
| 2082 |
} |
| 2083 |
#line 2084 "config-parser.c" /* yacc.c:1646 */ |
| 2084 |
break; |
| 2085 |
|
| 2086 |
case 124: |
| 2087 |
#line 545 "config-parser.y" /* yacc.c:1646 */ |
| 2088 |
{ |
| 2089 |
node_t *node; |
| 2090 |
struct BlacklistConf *item; |
| 2091 |
|
| 2092 |
item = MyMalloc(sizeof *item); |
| 2093 |
|
| 2094 |
item->name = xstrdup(""); |
| 2095 |
item->kline = xstrdup(""); |
| 2096 |
item->ban_unknown = 0; |
| 2097 |
item->type = A_BITMASK; |
| 2098 |
item->reply = list_create(); |
| 2099 |
|
| 2100 |
node = node_create(item); |
| 2101 |
list_add(OpmItem->blacklists, node); |
| 2102 |
|
| 2103 |
tmp = (void *) item; |
| 2104 |
} |
| 2105 |
#line 2106 "config-parser.c" /* yacc.c:1646 */ |
| 2106 |
break; |
| 2107 |
|
| 2108 |
case 134: |
| 2109 |
#line 574 "config-parser.y" /* yacc.c:1646 */ |
| 2110 |
{ |
| 2111 |
struct BlacklistConf *item = tmp; |
| 2112 |
|
| 2113 |
MyFree(item->name); |
| 2114 |
item->name = xstrdup((yyvsp[-1].string)); |
| 2115 |
} |
| 2116 |
#line 2117 "config-parser.c" /* yacc.c:1646 */ |
| 2117 |
break; |
| 2118 |
|
| 2119 |
case 135: |
| 2120 |
#line 581 "config-parser.y" /* yacc.c:1646 */ |
| 2121 |
{ |
| 2122 |
struct BlacklistConf *item = tmp; |
| 2123 |
|
| 2124 |
MyFree(item->kline); |
| 2125 |
item->kline = xstrdup((yyvsp[-1].string)); |
| 2126 |
} |
| 2127 |
#line 2128 "config-parser.c" /* yacc.c:1646 */ |
| 2128 |
break; |
| 2129 |
|
| 2130 |
case 136: |
| 2131 |
#line 588 "config-parser.y" /* yacc.c:1646 */ |
| 2132 |
{ |
| 2133 |
struct BlacklistConf *item = tmp; |
| 2134 |
|
| 2135 |
if(strcmp("A record bitmask", (yyvsp[-1].string)) == 0) |
| 2136 |
item->type = A_BITMASK; |
| 2137 |
else if(strcmp("A record reply", (yyvsp[-1].string)) == 0) |
| 2138 |
item->type = A_REPLY; |
| 2139 |
else |
| 2140 |
yyerror("Unknown blacklist type defined"); |
| 2141 |
} |
| 2142 |
#line 2143 "config-parser.c" /* yacc.c:1646 */ |
| 2143 |
break; |
| 2144 |
|
| 2145 |
case 137: |
| 2146 |
#line 599 "config-parser.y" /* yacc.c:1646 */ |
| 2147 |
{ |
| 2148 |
struct BlacklistConf *item = tmp; |
| 2149 |
|
| 2150 |
item->ban_unknown = (yyvsp[-1].number); |
| 2151 |
} |
| 2152 |
#line 2153 "config-parser.c" /* yacc.c:1646 */ |
| 2153 |
break; |
| 2154 |
|
| 2155 |
case 141: |
| 2156 |
#line 611 "config-parser.y" /* yacc.c:1646 */ |
| 2157 |
{ |
| 2158 |
struct BlacklistReplyConf *item; |
| 2159 |
struct BlacklistConf *blacklist = tmp; |
| 2160 |
node_t *node; |
| 2161 |
|
| 2162 |
item = MyMalloc(sizeof *item); |
| 2163 |
|
| 2164 |
item->number = (yyvsp[-3].number); |
| 2165 |
item->type = xstrdup((yyvsp[-1].string)); |
| 2166 |
|
| 2167 |
node = node_create(item); |
| 2168 |
list_add(blacklist->reply, node); |
| 2169 |
} |
| 2170 |
#line 2171 "config-parser.c" /* yacc.c:1646 */ |
| 2171 |
break; |
| 2172 |
|
| 2173 |
case 147: |
| 2174 |
#line 637 "config-parser.y" /* yacc.c:1646 */ |
| 2175 |
{ |
| 2176 |
node_t *node; |
| 2177 |
node = node_create(xstrdup((yyvsp[-1].string))); |
| 2178 |
|
| 2179 |
list_add(ExemptItem->masks, node); |
| 2180 |
} |
| 2181 |
#line 2182 "config-parser.c" /* yacc.c:1646 */ |
| 2182 |
break; |
| 2183 |
|
| 2184 |
|
| 2185 |
#line 2186 "config-parser.c" /* yacc.c:1646 */ |
| 2186 |
default: break; |
| 2187 |
} |
| 2188 |
/* User semantic actions sometimes alter yychar, and that requires |
| 2189 |
that yytoken be updated with the new translation. We take the |
| 2190 |
approach of translating immediately before every use of yytoken. |
| 2191 |
One alternative is translating here after every semantic action, |
| 2192 |
but that translation would be missed if the semantic action invokes |
| 2193 |
YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or |
| 2194 |
if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an |
| 2195 |
incorrect destructor might then be invoked immediately. In the |
| 2196 |
case of YYERROR or YYBACKUP, subsequent parser actions might lead |
| 2197 |
to an incorrect destructor call or verbose syntax error message |
| 2198 |
before the lookahead is translated. */ |
| 2199 |
YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); |
| 2200 |
|
| 2201 |
YYPOPSTACK (yylen); |
| 2202 |
yylen = 0; |
| 2203 |
YY_STACK_PRINT (yyss, yyssp); |
| 2204 |
|
| 2205 |
*++yyvsp = yyval; |
| 2206 |
|
| 2207 |
/* Now 'shift' the result of the reduction. Determine what state |
| 2208 |
that goes to, based on the state we popped back to and the rule |
| 2209 |
number reduced by. */ |
| 2210 |
|
| 2211 |
yyn = yyr1[yyn]; |
| 2212 |
|
| 2213 |
yystate = yypgoto[yyn - YYNTOKENS] + *yyssp; |
| 2214 |
if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp) |
| 2215 |
yystate = yytable[yystate]; |
| 2216 |
else |
| 2217 |
yystate = yydefgoto[yyn - YYNTOKENS]; |
| 2218 |
|
| 2219 |
goto yynewstate; |
| 2220 |
|
| 2221 |
|
| 2222 |
/*--------------------------------------. |
| 2223 |
| yyerrlab -- here on detecting error. | |
| 2224 |
`--------------------------------------*/ |
| 2225 |
yyerrlab: |
| 2226 |
/* Make sure we have latest lookahead translation. See comments at |
| 2227 |
user semantic actions for why this is necessary. */ |
| 2228 |
yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar); |
| 2229 |
|
| 2230 |
/* If not already recovering from an error, report this error. */ |
| 2231 |
if (!yyerrstatus) |
| 2232 |
{ |
| 2233 |
++yynerrs; |
| 2234 |
#if ! YYERROR_VERBOSE |
| 2235 |
yyerror (YY_("syntax error")); |
| 2236 |
#else |
| 2237 |
# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \ |
| 2238 |
yyssp, yytoken) |
| 2239 |
{ |
| 2240 |
char const *yymsgp = YY_("syntax error"); |
| 2241 |
int yysyntax_error_status; |
| 2242 |
yysyntax_error_status = YYSYNTAX_ERROR; |
| 2243 |
if (yysyntax_error_status == 0) |
| 2244 |
yymsgp = yymsg; |
| 2245 |
else if (yysyntax_error_status == 1) |
| 2246 |
{ |
| 2247 |
if (yymsg != yymsgbuf) |
| 2248 |
YYSTACK_FREE (yymsg); |
| 2249 |
yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc); |
| 2250 |
if (!yymsg) |
| 2251 |
{ |
| 2252 |
yymsg = yymsgbuf; |
| 2253 |
yymsg_alloc = sizeof yymsgbuf; |
| 2254 |
yysyntax_error_status = 2; |
| 2255 |
} |
| 2256 |
else |
| 2257 |
{ |
| 2258 |
yysyntax_error_status = YYSYNTAX_ERROR; |
| 2259 |
yymsgp = yymsg; |
| 2260 |
} |
| 2261 |
} |
| 2262 |
yyerror (yymsgp); |
| 2263 |
if (yysyntax_error_status == 2) |
| 2264 |
goto yyexhaustedlab; |
| 2265 |
} |
| 2266 |
# undef YYSYNTAX_ERROR |
| 2267 |
#endif |
| 2268 |
} |
| 2269 |
|
| 2270 |
|
| 2271 |
|
| 2272 |
if (yyerrstatus == 3) |
| 2273 |
{ |
| 2274 |
/* If just tried and failed to reuse lookahead token after an |
| 2275 |
error, discard it. */ |
| 2276 |
|
| 2277 |
if (yychar <= YYEOF) |
| 2278 |
{ |
| 2279 |
/* Return failure if at end of input. */ |
| 2280 |
if (yychar == YYEOF) |
| 2281 |
YYABORT; |
| 2282 |
} |
| 2283 |
else |
| 2284 |
{ |
| 2285 |
yydestruct ("Error: discarding", |
| 2286 |
yytoken, &yylval); |
| 2287 |
yychar = YYEMPTY; |
| 2288 |
} |
| 2289 |
} |
| 2290 |
|
| 2291 |
/* Else will try to reuse lookahead token after shifting the error |
| 2292 |
token. */ |
| 2293 |
goto yyerrlab1; |
| 2294 |
|
| 2295 |
|
| 2296 |
/*---------------------------------------------------. |
| 2297 |
| yyerrorlab -- error raised explicitly by YYERROR. | |
| 2298 |
`---------------------------------------------------*/ |
| 2299 |
yyerrorlab: |
| 2300 |
|
| 2301 |
/* Pacify compilers like GCC when the user code never invokes |
| 2302 |
YYERROR and the label yyerrorlab therefore never appears in user |
| 2303 |
code. */ |
| 2304 |
if (/*CONSTCOND*/ 0) |
| 2305 |
goto yyerrorlab; |
| 2306 |
|
| 2307 |
/* Do not reclaim the symbols of the rule whose action triggered |
| 2308 |
this YYERROR. */ |
| 2309 |
YYPOPSTACK (yylen); |
| 2310 |
yylen = 0; |
| 2311 |
YY_STACK_PRINT (yyss, yyssp); |
| 2312 |
yystate = *yyssp; |
| 2313 |
goto yyerrlab1; |
| 2314 |
|
| 2315 |
|
| 2316 |
/*-------------------------------------------------------------. |
| 2317 |
| yyerrlab1 -- common code for both syntax error and YYERROR. | |
| 2318 |
`-------------------------------------------------------------*/ |
| 2319 |
yyerrlab1: |
| 2320 |
yyerrstatus = 3; /* Each real token shifted decrements this. */ |
| 2321 |
|
| 2322 |
for (;;) |
| 2323 |
{ |
| 2324 |
yyn = yypact[yystate]; |
| 2325 |
if (!yypact_value_is_default (yyn)) |
| 2326 |
{ |
| 2327 |
yyn += YYTERROR; |
| 2328 |
if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) |
| 2329 |
{ |
| 2330 |
yyn = yytable[yyn]; |
| 2331 |
if (0 < yyn) |
| 2332 |
break; |
| 2333 |
} |
| 2334 |
} |
| 2335 |
|
| 2336 |
/* Pop the current state because it cannot handle the error token. */ |
| 2337 |
if (yyssp == yyss) |
| 2338 |
YYABORT; |
| 2339 |
|
| 2340 |
|
| 2341 |
yydestruct ("Error: popping", |
| 2342 |
yystos[yystate], yyvsp); |
| 2343 |
YYPOPSTACK (1); |
| 2344 |
yystate = *yyssp; |
| 2345 |
YY_STACK_PRINT (yyss, yyssp); |
| 2346 |
} |
| 2347 |
|
| 2348 |
YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN |
| 2349 |
*++yyvsp = yylval; |
| 2350 |
YY_IGNORE_MAYBE_UNINITIALIZED_END |
| 2351 |
|
| 2352 |
|
| 2353 |
/* Shift the error token. */ |
| 2354 |
YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp); |
| 2355 |
|
| 2356 |
yystate = yyn; |
| 2357 |
goto yynewstate; |
| 2358 |
|
| 2359 |
|
| 2360 |
/*-------------------------------------. |
| 2361 |
| yyacceptlab -- YYACCEPT comes here. | |
| 2362 |
`-------------------------------------*/ |
| 2363 |
yyacceptlab: |
| 2364 |
yyresult = 0; |
| 2365 |
goto yyreturn; |
| 2366 |
|
| 2367 |
/*-----------------------------------. |
| 2368 |
| yyabortlab -- YYABORT comes here. | |
| 2369 |
`-----------------------------------*/ |
| 2370 |
yyabortlab: |
| 2371 |
yyresult = 1; |
| 2372 |
goto yyreturn; |
| 2373 |
|
| 2374 |
#if !defined yyoverflow || YYERROR_VERBOSE |
| 2375 |
/*-------------------------------------------------. |
| 2376 |
| yyexhaustedlab -- memory exhaustion comes here. | |
| 2377 |
`-------------------------------------------------*/ |
| 2378 |
yyexhaustedlab: |
| 2379 |
yyerror (YY_("memory exhausted")); |
| 2380 |
yyresult = 2; |
| 2381 |
/* Fall through. */ |
| 2382 |
#endif |
| 2383 |
|
| 2384 |
yyreturn: |
| 2385 |
if (yychar != YYEMPTY) |
| 2386 |
{ |
| 2387 |
/* Make sure we have latest lookahead translation. See comments at |
| 2388 |
user semantic actions for why this is necessary. */ |
| 2389 |
yytoken = YYTRANSLATE (yychar); |
| 2390 |
yydestruct ("Cleanup: discarding lookahead", |
| 2391 |
yytoken, &yylval); |
| 2392 |
} |
| 2393 |
/* Do not reclaim the symbols of the rule whose action triggered |
| 2394 |
this YYABORT or YYACCEPT. */ |
| 2395 |
YYPOPSTACK (yylen); |
| 2396 |
YY_STACK_PRINT (yyss, yyssp); |
| 2397 |
while (yyssp != yyss) |
| 2398 |
{ |
| 2399 |
yydestruct ("Cleanup: popping", |
| 2400 |
yystos[*yyssp], yyvsp); |
| 2401 |
YYPOPSTACK (1); |
| 2402 |
} |
| 2403 |
#ifndef yyoverflow |
| 2404 |
if (yyss != yyssa) |
| 2405 |
YYSTACK_FREE (yyss); |
| 2406 |
#endif |
| 2407 |
#if YYERROR_VERBOSE |
| 2408 |
if (yymsg != yymsgbuf) |
| 2409 |
YYSTACK_FREE (yymsg); |
| 2410 |
#endif |
| 2411 |
return yyresult; |
| 2412 |
} |
| 2413 |
#line 644 "config-parser.y" /* yacc.c:1906 */ |
| 2414 |
|