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