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