Coverage Report

Created: 2024-02-29 06:05

/src/strongswan/src/libstrongswan/settings/settings_lexer.c
Line
Count
Source (jump to first uncovered line)
1
#line 2 "settings/settings_lexer.c"
2
3
#line 4 "settings/settings_lexer.c"
4
5
#define  YY_INT_ALIGNED short int
6
7
/* A lexical scanner generated by flex */
8
9
/* %not-for-header */
10
/* %if-c-only */
11
/* %if-not-reentrant */
12
/* %endif */
13
/* %endif */
14
/* %ok-for-header */
15
16
#define FLEX_SCANNER
17
#define YY_FLEX_MAJOR_VERSION 2
18
#define YY_FLEX_MINOR_VERSION 6
19
#define YY_FLEX_SUBMINOR_VERSION 4
20
#if YY_FLEX_SUBMINOR_VERSION > 0
21
#define FLEX_BETA
22
#endif
23
24
/* %if-c++-only */
25
/* %endif */
26
27
/* %if-c-only */
28
#ifdef yy_create_buffer
29
#define settings_parser__create_buffer_ALREADY_DEFINED
30
#else
31
0
#define yy_create_buffer settings_parser__create_buffer
32
#endif
33
34
#ifdef yy_delete_buffer
35
#define settings_parser__delete_buffer_ALREADY_DEFINED
36
#else
37
0
#define yy_delete_buffer settings_parser__delete_buffer
38
#endif
39
40
#ifdef yy_scan_buffer
41
#define settings_parser__scan_buffer_ALREADY_DEFINED
42
#else
43
0
#define yy_scan_buffer settings_parser__scan_buffer
44
#endif
45
46
#ifdef yy_scan_string
47
#define settings_parser__scan_string_ALREADY_DEFINED
48
#else
49
#define yy_scan_string settings_parser__scan_string
50
#endif
51
52
#ifdef yy_scan_bytes
53
#define settings_parser__scan_bytes_ALREADY_DEFINED
54
#else
55
0
#define yy_scan_bytes settings_parser__scan_bytes
56
#endif
57
58
#ifdef yy_init_buffer
59
#define settings_parser__init_buffer_ALREADY_DEFINED
60
#else
61
0
#define yy_init_buffer settings_parser__init_buffer
62
#endif
63
64
#ifdef yy_flush_buffer
65
#define settings_parser__flush_buffer_ALREADY_DEFINED
66
#else
67
0
#define yy_flush_buffer settings_parser__flush_buffer
68
#endif
69
70
#ifdef yy_load_buffer_state
71
#define settings_parser__load_buffer_state_ALREADY_DEFINED
72
#else
73
0
#define yy_load_buffer_state settings_parser__load_buffer_state
74
#endif
75
76
#ifdef yy_switch_to_buffer
77
#define settings_parser__switch_to_buffer_ALREADY_DEFINED
78
#else
79
0
#define yy_switch_to_buffer settings_parser__switch_to_buffer
80
#endif
81
82
#ifdef yypush_buffer_state
83
#define settings_parser_push_buffer_state_ALREADY_DEFINED
84
#else
85
#define yypush_buffer_state settings_parser_push_buffer_state
86
#endif
87
88
#ifdef yypop_buffer_state
89
#define settings_parser_pop_buffer_state_ALREADY_DEFINED
90
#else
91
0
#define yypop_buffer_state settings_parser_pop_buffer_state
92
#endif
93
94
#ifdef yyensure_buffer_stack
95
#define settings_parser_ensure_buffer_stack_ALREADY_DEFINED
96
#else
97
0
#define yyensure_buffer_stack settings_parser_ensure_buffer_stack
98
#endif
99
100
#ifdef yylex
101
#define settings_parser_lex_ALREADY_DEFINED
102
#else
103
#define yylex settings_parser_lex
104
#endif
105
106
#ifdef yyrestart
107
#define settings_parser_restart_ALREADY_DEFINED
108
#else
109
0
#define yyrestart settings_parser_restart
110
#endif
111
112
#ifdef yylex_init
113
#define settings_parser_lex_init_ALREADY_DEFINED
114
#else
115
#define yylex_init settings_parser_lex_init
116
#endif
117
118
#ifdef yylex_init_extra
119
#define settings_parser_lex_init_extra_ALREADY_DEFINED
120
#else
121
#define yylex_init_extra settings_parser_lex_init_extra
122
#endif
123
124
#ifdef yylex_destroy
125
#define settings_parser_lex_destroy_ALREADY_DEFINED
126
#else
127
#define yylex_destroy settings_parser_lex_destroy
128
#endif
129
130
#ifdef yyget_debug
131
#define settings_parser_get_debug_ALREADY_DEFINED
132
#else
133
#define yyget_debug settings_parser_get_debug
134
#endif
135
136
#ifdef yyset_debug
137
#define settings_parser_set_debug_ALREADY_DEFINED
138
#else
139
#define yyset_debug settings_parser_set_debug
140
#endif
141
142
#ifdef yyget_extra
143
#define settings_parser_get_extra_ALREADY_DEFINED
144
#else
145
#define yyget_extra settings_parser_get_extra
146
#endif
147
148
#ifdef yyset_extra
149
#define settings_parser_set_extra_ALREADY_DEFINED
150
#else
151
9.78k
#define yyset_extra settings_parser_set_extra
152
#endif
153
154
#ifdef yyget_in
155
#define settings_parser_get_in_ALREADY_DEFINED
156
#else
157
#define yyget_in settings_parser_get_in
158
#endif
159
160
#ifdef yyset_in
161
#define settings_parser_set_in_ALREADY_DEFINED
162
#else
163
#define yyset_in settings_parser_set_in
164
#endif
165
166
#ifdef yyget_out
167
#define settings_parser_get_out_ALREADY_DEFINED
168
#else
169
#define yyget_out settings_parser_get_out
170
#endif
171
172
#ifdef yyset_out
173
#define settings_parser_set_out_ALREADY_DEFINED
174
#else
175
#define yyset_out settings_parser_set_out
176
#endif
177
178
#ifdef yyget_leng
179
#define settings_parser_get_leng_ALREADY_DEFINED
180
#else
181
#define yyget_leng settings_parser_get_leng
182
#endif
183
184
#ifdef yyget_text
185
#define settings_parser_get_text_ALREADY_DEFINED
186
#else
187
#define yyget_text settings_parser_get_text
188
#endif
189
190
#ifdef yyget_lineno
191
#define settings_parser_get_lineno_ALREADY_DEFINED
192
#else
193
#define yyget_lineno settings_parser_get_lineno
194
#endif
195
196
#ifdef yyset_lineno
197
#define settings_parser_set_lineno_ALREADY_DEFINED
198
#else
199
#define yyset_lineno settings_parser_set_lineno
200
#endif
201
202
#ifdef yyget_column
203
#define settings_parser_get_column_ALREADY_DEFINED
204
#else
205
#define yyget_column settings_parser_get_column
206
#endif
207
208
#ifdef yyset_column
209
#define settings_parser_set_column_ALREADY_DEFINED
210
#else
211
#define yyset_column settings_parser_set_column
212
#endif
213
214
#ifdef yywrap
215
#define settings_parser_wrap_ALREADY_DEFINED
216
#else
217
0
#define yywrap settings_parser_wrap
218
#endif
219
220
/* %endif */
221
222
#ifdef yyalloc
223
#define settings_parser_alloc_ALREADY_DEFINED
224
#else
225
4.89k
#define yyalloc settings_parser_alloc
226
#endif
227
228
#ifdef yyrealloc
229
#define settings_parser_realloc_ALREADY_DEFINED
230
#else
231
0
#define yyrealloc settings_parser_realloc
232
#endif
233
234
#ifdef yyfree
235
#define settings_parser_free_ALREADY_DEFINED
236
#else
237
14.6k
#define yyfree settings_parser_free
238
#endif
239
240
/* %if-c-only */
241
242
/* %endif */
243
244
/* First, we deal with  platform-specific or compiler-specific issues. */
245
246
/* begin standard C headers. */
247
/* %if-c-only */
248
#include <stdio.h>
249
#include <string.h>
250
#include <errno.h>
251
#include <stdlib.h>
252
/* %endif */
253
254
/* %if-tables-serialization */
255
/* %endif */
256
/* end standard C headers. */
257
258
/* %if-c-or-c++ */
259
/* flex integer type definitions */
260
261
#ifndef FLEXINT_H
262
#define FLEXINT_H
263
264
/* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
265
266
#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
267
268
/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
269
 * if you want the limit (max/min) macros for int types. 
270
 */
271
#ifndef __STDC_LIMIT_MACROS
272
#define __STDC_LIMIT_MACROS 1
273
#endif
274
275
#include <inttypes.h>
276
typedef int8_t flex_int8_t;
277
typedef uint8_t flex_uint8_t;
278
typedef int16_t flex_int16_t;
279
typedef uint16_t flex_uint16_t;
280
typedef int32_t flex_int32_t;
281
typedef uint32_t flex_uint32_t;
282
#else
283
typedef signed char flex_int8_t;
284
typedef short int flex_int16_t;
285
typedef int flex_int32_t;
286
typedef unsigned char flex_uint8_t; 
287
typedef unsigned short int flex_uint16_t;
288
typedef unsigned int flex_uint32_t;
289
290
/* Limits of integral types. */
291
#ifndef INT8_MIN
292
#define INT8_MIN               (-128)
293
#endif
294
#ifndef INT16_MIN
295
#define INT16_MIN              (-32767-1)
296
#endif
297
#ifndef INT32_MIN
298
#define INT32_MIN              (-2147483647-1)
299
#endif
300
#ifndef INT8_MAX
301
#define INT8_MAX               (127)
302
#endif
303
#ifndef INT16_MAX
304
#define INT16_MAX              (32767)
305
#endif
306
#ifndef INT32_MAX
307
#define INT32_MAX              (2147483647)
308
#endif
309
#ifndef UINT8_MAX
310
#define UINT8_MAX              (255U)
311
#endif
312
#ifndef UINT16_MAX
313
#define UINT16_MAX             (65535U)
314
#endif
315
#ifndef UINT32_MAX
316
#define UINT32_MAX             (4294967295U)
317
#endif
318
319
#ifndef SIZE_MAX
320
#define SIZE_MAX               (~(size_t)0)
321
#endif
322
323
#endif /* ! C99 */
324
325
#endif /* ! FLEXINT_H */
326
327
/* %endif */
328
329
/* begin standard C++ headers. */
330
/* %if-c++-only */
331
/* %endif */
332
333
/* TODO: this is always defined, so inline it */
334
#define yyconst const
335
336
#if defined(__GNUC__) && __GNUC__ >= 3
337
#define yynoreturn __attribute__((__noreturn__))
338
#else
339
#define yynoreturn
340
#endif
341
342
/* %not-for-header */
343
/* Returned upon end-of-file. */
344
0
#define YY_NULL 0
345
/* %ok-for-header */
346
347
/* %not-for-header */
348
/* Promotes a possibly negative, possibly signed char to an
349
 *   integer in range [0..255] for use as an array index.
350
 */
351
0
#define YY_SC_TO_UI(c) ((YY_CHAR) (c))
352
/* %ok-for-header */
353
354
/* %if-reentrant */
355
356
/* An opaque pointer. */
357
#ifndef YY_TYPEDEF_YY_SCANNER_T
358
#define YY_TYPEDEF_YY_SCANNER_T
359
typedef void* yyscan_t;
360
#endif
361
362
/* For convenience, these vars (plus the bison vars far below)
363
   are macros in the reentrant scanner. */
364
9.78k
#define yyin yyg->yyin_r
365
9.78k
#define yyout yyg->yyout_r
366
9.78k
#define yyextra yyg->yyextra_r
367
0
#define yyleng yyg->yyleng_r
368
0
#define yytext yyg->yytext_r
369
0
#define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
370
0
#define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
371
0
#define yy_flex_debug yyg->yy_flex_debug_r
372
373
/* %endif */
374
375
/* %if-not-reentrant */
376
/* %endif */
377
378
/* Enter a start condition.  This macro really ought to take a parameter,
379
 * but we do it the disgusting crufty way forced on us by the ()-less
380
 * definition of BEGIN.
381
 */
382
0
#define BEGIN yyg->yy_start = 1 + 2 *
383
/* Translate the current start state into a value that can be later handed
384
 * to BEGIN to return to the state.  The YYSTATE alias is for lex
385
 * compatibility.
386
 */
387
0
#define YY_START ((yyg->yy_start - 1) / 2)
388
#define YYSTATE YY_START
389
/* Action number for EOF rule of a given start state. */
390
0
#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
391
/* Special action meaning "start processing a new file". */
392
0
#define YY_NEW_FILE yyrestart( yyin , yyscanner )
393
0
#define YY_END_OF_BUFFER_CHAR 0
394
395
/* Size of default input buffer. */
396
#ifndef YY_BUF_SIZE
397
#ifdef __ia64__
398
/* On IA-64, the buffer size is 16k, not 8k.
399
 * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
400
 * Ditto for the __ia64__ case accordingly.
401
 */
402
#define YY_BUF_SIZE 32768
403
#else
404
0
#define YY_BUF_SIZE 16384
405
#endif /* __ia64__ */
406
#endif
407
408
/* The state buf must be large enough to hold one state per character in the main buffer.
409
 */
410
#define YY_STATE_BUF_SIZE   ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
411
412
#ifndef YY_TYPEDEF_YY_BUFFER_STATE
413
#define YY_TYPEDEF_YY_BUFFER_STATE
414
typedef struct yy_buffer_state *YY_BUFFER_STATE;
415
#endif
416
417
#ifndef YY_TYPEDEF_YY_SIZE_T
418
#define YY_TYPEDEF_YY_SIZE_T
419
typedef size_t yy_size_t;
420
#endif
421
422
/* %if-not-reentrant */
423
/* %endif */
424
425
/* %if-c-only */
426
/* %if-not-reentrant */
427
/* %endif */
428
/* %endif */
429
430
0
#define EOB_ACT_CONTINUE_SCAN 0
431
0
#define EOB_ACT_END_OF_FILE 1
432
0
#define EOB_ACT_LAST_MATCH 2
433
    
434
    /* Note: We specifically omit the test for yy_rule_can_match_eol because it requires
435
     *       access to the local variable yy_act. Since yyless() is a macro, it would break
436
     *       existing scanners that call yyless() from OUTSIDE yylex.
437
     *       One obvious solution it to make yy_act a global. I tried that, and saw
438
     *       a 5% performance hit in a non-yylineno scanner, because yy_act is
439
     *       normally declared as a register variable-- so it is not worth it.
440
     */
441
    #define  YY_LESS_LINENO(n) \
442
            do { \
443
                int yyl;\
444
                for ( yyl = n; yyl < yyleng; ++yyl )\
445
                    if ( yytext[yyl] == '\n' )\
446
                        --yylineno;\
447
            }while(0)
448
    #define YY_LINENO_REWIND_TO(dst) \
449
0
            do {\
450
0
                const char *p;\
451
0
                for ( p = yy_cp-1; p >= (dst); --p)\
452
0
                    if ( *p == '\n' )\
453
0
                        --yylineno;\
454
0
            }while(0)
455
    
456
/* Return all but the first "n" matched characters back to the input stream. */
457
#define yyless(n) \
458
  do \
459
    { \
460
    /* Undo effects of setting up yytext. */ \
461
        int yyless_macro_arg = (n); \
462
        YY_LESS_LINENO(yyless_macro_arg);\
463
    *yy_cp = yyg->yy_hold_char; \
464
    YY_RESTORE_YY_MORE_OFFSET \
465
    yyg->yy_c_buf_p = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
466
    YY_DO_BEFORE_ACTION; /* set up yytext again */ \
467
    } \
468
  while ( 0 )
469
0
#define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner )
470
471
#ifndef YY_STRUCT_YY_BUFFER_STATE
472
#define YY_STRUCT_YY_BUFFER_STATE
473
struct yy_buffer_state
474
  {
475
/* %if-c-only */
476
  FILE *yy_input_file;
477
/* %endif */
478
479
/* %if-c++-only */
480
/* %endif */
481
482
  char *yy_ch_buf;    /* input buffer */
483
  char *yy_buf_pos;   /* current position in input buffer */
484
485
  /* Size of input buffer in bytes, not including room for EOB
486
   * characters.
487
   */
488
  int yy_buf_size;
489
490
  /* Number of characters read into yy_ch_buf, not including EOB
491
   * characters.
492
   */
493
  int yy_n_chars;
494
495
  /* Whether we "own" the buffer - i.e., we know we created it,
496
   * and can realloc() it to grow it, and should free() it to
497
   * delete it.
498
   */
499
  int yy_is_our_buffer;
500
501
  /* Whether this is an "interactive" input source; if so, and
502
   * if we're using stdio for input, then we want to use getc()
503
   * instead of fread(), to make sure we stop fetching input after
504
   * each newline.
505
   */
506
  int yy_is_interactive;
507
508
  /* Whether we're considered to be at the beginning of a line.
509
   * If so, '^' rules will be active on the next match, otherwise
510
   * not.
511
   */
512
  int yy_at_bol;
513
514
    int yy_bs_lineno; /**< The line count. */
515
    int yy_bs_column; /**< The column count. */
516
517
  /* Whether to try to fill the input buffer when we reach the
518
   * end of it.
519
   */
520
  int yy_fill_buffer;
521
522
  int yy_buffer_status;
523
524
0
#define YY_BUFFER_NEW 0
525
0
#define YY_BUFFER_NORMAL 1
526
  /* When an EOF's been seen but there's still some text to process
527
   * then we mark the buffer as YY_EOF_PENDING, to indicate that we
528
   * shouldn't try reading from the input source any more.  We might
529
   * still have a bunch of tokens to match, though, because of
530
   * possible backing-up.
531
   *
532
   * When we actually see the EOF, we change the status to "new"
533
   * (via yyrestart()), so that the user can continue scanning by
534
   * just pointing yyin at a new input file.
535
   */
536
0
#define YY_BUFFER_EOF_PENDING 2
537
538
  };
539
#endif /* !YY_STRUCT_YY_BUFFER_STATE */
540
541
/* %if-c-only Standard (non-C++) definition */
542
/* %not-for-header */
543
/* %if-not-reentrant */
544
/* %endif */
545
/* %ok-for-header */
546
547
/* %endif */
548
549
/* We provide macros for accessing buffer states in case in the
550
 * future we want to put the buffer states in a more general
551
 * "scanner state".
552
 *
553
 * Returns the top of the stack, or NULL.
554
 */
555
4.89k
#define YY_CURRENT_BUFFER ( yyg->yy_buffer_stack \
556
4.89k
                          ? yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] \
557
4.89k
                          : NULL)
558
/* Same as previous macro, but useful when we know that the buffer stack is not
559
 * NULL or when we need an lvalue. For internal use only.
560
 */
561
0
#define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
562
563
/* %if-c-only Standard (non-C++) definition */
564
565
/* %if-not-reentrant */
566
/* %not-for-header */
567
/* %ok-for-header */
568
569
/* %endif */
570
571
void yyrestart ( FILE *input_file , yyscan_t yyscanner );
572
void yy_switch_to_buffer ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
573
YY_BUFFER_STATE yy_create_buffer ( FILE *file, int size , yyscan_t yyscanner );
574
void yy_delete_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
575
void yy_flush_buffer ( YY_BUFFER_STATE b , yyscan_t yyscanner );
576
void yypush_buffer_state ( YY_BUFFER_STATE new_buffer , yyscan_t yyscanner );
577
void yypop_buffer_state ( yyscan_t yyscanner );
578
579
static void yyensure_buffer_stack ( yyscan_t yyscanner );
580
static void yy_load_buffer_state ( yyscan_t yyscanner );
581
static void yy_init_buffer ( YY_BUFFER_STATE b, FILE *file , yyscan_t yyscanner );
582
#define YY_FLUSH_BUFFER yy_flush_buffer( YY_CURRENT_BUFFER , yyscanner)
583
584
YY_BUFFER_STATE yy_scan_buffer ( char *base, yy_size_t size , yyscan_t yyscanner );
585
YY_BUFFER_STATE yy_scan_string ( const char *yy_str , yyscan_t yyscanner );
586
YY_BUFFER_STATE yy_scan_bytes ( const char *bytes, int len , yyscan_t yyscanner );
587
588
/* %endif */
589
590
void *yyalloc ( yy_size_t , yyscan_t yyscanner );
591
void *yyrealloc ( void *, yy_size_t , yyscan_t yyscanner );
592
void yyfree ( void * , yyscan_t yyscanner );
593
594
#define yy_new_buffer yy_create_buffer
595
#define yy_set_interactive(is_interactive) \
596
  { \
597
  if ( ! YY_CURRENT_BUFFER ){ \
598
        yyensure_buffer_stack (yyscanner); \
599
    YY_CURRENT_BUFFER_LVALUE =    \
600
            yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner); \
601
  } \
602
  YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
603
  }
604
#define yy_set_bol(at_bol) \
605
0
  { \
606
0
  if ( ! YY_CURRENT_BUFFER ){\
607
0
        yyensure_buffer_stack (yyscanner); \
608
0
    YY_CURRENT_BUFFER_LVALUE =    \
609
0
            yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner); \
610
0
  } \
611
0
  YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
612
0
  }
613
#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
614
615
/* %% [1.0] yytext/yyin/yyout/yy_state_type/yylineno etc. def's & init go here */
616
/* Begin user sect3 */
617
618
0
#define settings_parser_wrap(yyscanner) (/*CONSTCOND*/1)
619
#define YY_SKIP_YYWRAP
620
621
#define FLEX_DEBUG
622
typedef flex_uint8_t YY_CHAR;
623
624
typedef int yy_state_type;
625
626
0
#define yytext_ptr yytext_r
627
628
/* %% [1.5] DFA */
629
630
/* %if-c-only Standard (non-C++) definition */
631
632
static yy_state_type yy_get_previous_state ( yyscan_t yyscanner );
633
static yy_state_type yy_try_NUL_trans ( yy_state_type current_state  , yyscan_t yyscanner);
634
static int yy_get_next_buffer ( yyscan_t yyscanner );
635
static void yynoreturn yy_fatal_error ( const char* msg , yyscan_t yyscanner );
636
637
/* %endif */
638
639
/* Done after the current pattern has been matched and before the
640
 * corresponding action - sets up yytext.
641
 */
642
#define YY_DO_BEFORE_ACTION \
643
0
  yyg->yytext_ptr = yy_bp; \
644
0
/* %% [2.0] code to fiddle yytext and yyleng for yymore() goes here \ */\
645
0
  yyleng = (int) (yy_cp - yy_bp); \
646
0
  yyg->yy_hold_char = *yy_cp; \
647
0
  *yy_cp = '\0'; \
648
0
/* %% [3.0] code to copy yytext_ptr to yytext[] goes here, if %array \ */\
649
0
  yyg->yy_c_buf_p = yy_cp;
650
/* %% [4.0] data tables for the DFA and the user's section 1 definitions go here */
651
#define YY_NUM_RULES 39
652
0
#define YY_END_OF_BUFFER 40
653
/* This struct is not used in this scanner,
654
   but its presence is necessary. */
655
struct yy_trans_info
656
  {
657
  flex_int32_t yy_verify;
658
  flex_int32_t yy_nxt;
659
  };
660
static const flex_int16_t yy_accept[85] =
661
    {   0,
662
        0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
663
       40,   12,    2,    3,    2,   11,    1,    7,    6,    8,
664
        9,   12,    4,    5,   17,   14,   15,   14,   18,   13,
665
       16,   23,   20,   21,   19,   22,   29,   25,   24,   26,
666
       27,   38,   30,   31,   32,   12,    2,    2,    1,    1,
667
        3,    0,   12,   17,    0,   14,   14,   13,   13,   15,
668
        0,   23,   20,   29,   28,   38,   37,   36,   37,   33,
669
       34,   35,    1,   12,   17,   13,   12,   12,   12,   12,
670
        0,   10,   10,    0
671
    } ;
672
673
static const YY_CHAR yy_ec[256] =
674
    {   0,
675
        1,    1,    1,    1,    1,    1,    1,    1,    2,    3,
676
        1,    1,    4,    1,    1,    1,    1,    1,    1,    1,
677
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
678
        1,    5,    1,    6,    7,    1,    1,    1,    1,    1,
679
        1,    1,    1,    8,    1,    9,    1,    1,    1,    1,
680
        1,    1,    1,    1,    1,    1,    1,   10,    1,    1,
681
       11,    1,    1,    1,    1,    1,    1,    1,    1,    1,
682
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
683
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
684
        1,   12,    1,    1,    1,    1,    1,    1,   13,   14,
685
686
       15,    1,    1,    1,   16,    1,    1,   17,    1,   18,
687
        1,    1,    1,   19,    1,   20,   21,    1,    1,    1,
688
        1,    1,   22,    1,   23,    1,    1,    1,    1,    1,
689
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
690
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
691
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
692
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
693
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
694
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
695
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
696
697
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
698
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
699
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
700
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
701
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
702
        1,    1,    1,    1,    1
703
    } ;
704
705
static const YY_CHAR yy_meta[24] =
706
    {   0,
707
        1,    2,    3,    4,    5,    6,    5,    7,    8,    7,
708
        9,   10,    1,    1,    1,    1,    1,    1,    1,    1,
709
        1,    7,    5
710
    } ;
711
712
static const flex_int16_t yy_base[103] =
713
    {   0,
714
        0,    0,   23,    0,   45,   67,   89,  111,   49,   50,
715
      124,    0,  133,  335,   55,  335,   60,  335,  335,  335,
716
      335,  104,  335,  335,  112,  139,  335,   73,  335,   62,
717
      335,    0,   74,  335,  335,  335,    0,  335,  335,  335,
718
        0,    0,  335,  335,  144,    0,    0,   78,    0,   81,
719
      335,  117,  106,  102,    0,    0,   84,    0,   94,  335,
720
      107,    0,   97,    0,  335,    0,  335,  335,  106,  335,
721
      335,  335,    0,   89,   78,    0,   60,   53,   43,   98,
722
      102,  335,  103,  335,  164,  174,  184,  194,  204,  214,
723
      224,  234,  244,  249,  255,  264,  274,  284,  294,  304,
724
725
      314,  324
726
    } ;
727
728
static const flex_int16_t yy_def[103] =
729
    {   0,
730
       84,    1,   84,    3,   85,   85,   86,   86,   87,   87,
731
       84,   88,   84,   84,   84,   84,   89,   84,   84,   84,
732
       84,   88,   84,   84,   90,   84,   84,   84,   84,   91,
733
       84,   92,   84,   84,   84,   84,   93,   84,   84,   84,
734
       94,   95,   84,   84,   96,   88,   13,   84,   97,   89,
735
       84,   98,   88,   90,   99,   26,   84,  100,   91,   84,
736
      101,   92,   84,   93,   84,   95,   84,   84,   84,   84,
737
       84,   84,   97,   88,   99,  100,   88,   88,   88,   88,
738
      102,   84,  102,    0,   84,   84,   84,   84,   84,   84,
739
       84,   84,   84,   84,   84,   84,   84,   84,   84,   84,
740
741
       84,   84
742
    } ;
743
744
static const flex_int16_t yy_nxt[359] =
745
    {   0,
746
       12,   13,   14,   15,   13,   16,   17,   18,   19,   20,
747
       21,   12,   12,   12,   12,   22,   12,   12,   12,   12,
748
       12,   23,   24,   25,   26,   27,   28,   26,   29,   30,
749
       31,   29,   29,   29,   25,   25,   25,   25,   25,   25,
750
       25,   25,   25,   25,   29,   29,   33,   34,   35,   33,
751
       36,   34,   43,   43,   44,   44,   48,   80,   48,   48,
752
       45,   45,   51,   52,   60,   61,   79,   34,   33,   34,
753
       35,   33,   36,   34,   57,   63,   57,   57,   63,   48,
754
       78,   48,   48,   51,   52,   57,   55,   57,   57,   34,
755
       38,   38,   39,   38,   40,   38,   60,   61,   63,   81,
756
757
       41,   63,   81,   83,   83,   77,   83,   83,   68,   60,
758
       55,   38,   38,   38,   39,   38,   40,   38,   74,   51,
759
       55,   53,   41,   84,   84,   84,   84,   84,   84,   84,
760
       84,   84,   84,   38,   47,   84,   48,   47,   84,   49,
761
       56,   84,   57,   56,   84,   58,   68,   69,   84,   84,
762
       84,   84,   84,   84,   84,   84,   84,   84,   84,   84,
763
       84,   70,   71,   72,   32,   32,   32,   32,   32,   32,
764
       32,   32,   32,   32,   37,   37,   37,   37,   37,   37,
765
       37,   37,   37,   37,   42,   42,   42,   42,   42,   42,
766
       42,   42,   42,   42,   46,   84,   84,   84,   84,   84,
767
768
       84,   84,   84,   46,   50,   50,   50,   50,   50,   50,
769
       50,   50,   50,   50,   54,   84,   84,   84,   84,   84,
770
       84,   54,   84,   54,   59,   59,   59,   59,   59,   59,
771
       59,   59,   59,   59,   62,   84,   84,   84,   84,   84,
772
       62,   62,   62,   62,   64,   84,   84,   84,   84,   84,
773
       64,   64,   64,   65,   65,   66,   66,   66,   84,   66,
774
       84,   66,   66,   66,   67,   67,   67,   67,   67,   67,
775
       67,   67,   67,   67,   73,   73,   84,   84,   73,   73,
776
       73,   73,   73,   73,   52,   52,   52,   52,   52,   52,
777
       52,   52,   52,   52,   75,   84,   84,   84,   84,   84,
778
779
       84,   84,   84,   75,   76,   76,   84,   84,   76,   76,
780
       76,   76,   76,   76,   61,   61,   61,   61,   61,   61,
781
       61,   61,   61,   61,   82,   82,   82,   82,   82,   82,
782
       82,   82,   84,   82,   11,   84,   84,   84,   84,   84,
783
       84,   84,   84,   84,   84,   84,   84,   84,   84,   84,
784
       84,   84,   84,   84,   84,   84,   84,   84
785
    } ;
786
787
static const flex_int16_t yy_chk[359] =
788
    {   0,
789
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
790
        1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
791
        1,    1,    1,    3,    3,    3,    3,    3,    3,    3,
792
        3,    3,    3,    3,    3,    3,    3,    3,    3,    3,
793
        3,    3,    3,    3,    3,    3,    5,    5,    5,    5,
794
        5,    5,    9,   10,    9,   10,   15,   79,   15,   15,
795
        9,   10,   17,   17,   30,   30,   78,    5,    6,    6,
796
        6,    6,    6,    6,   28,   33,   28,   28,   33,   48,
797
       77,   48,   48,   50,   50,   57,   75,   57,   57,    6,
798
        7,    7,    7,    7,    7,    7,   59,   59,   63,   80,
799
800
        7,   63,   80,   81,   83,   74,   81,   83,   69,   61,
801
       54,    7,    8,    8,    8,    8,    8,    8,   53,   52,
802
       25,   22,    8,   11,    0,    0,    0,    0,    0,    0,
803
        0,    0,    0,    8,   13,    0,   13,   13,    0,   13,
804
       26,    0,   26,   26,    0,   26,   45,   45,    0,    0,
805
        0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
806
        0,   45,   45,   45,   85,   85,   85,   85,   85,   85,
807
       85,   85,   85,   85,   86,   86,   86,   86,   86,   86,
808
       86,   86,   86,   86,   87,   87,   87,   87,   87,   87,
809
       87,   87,   87,   87,   88,    0,    0,    0,    0,    0,
810
811
        0,    0,    0,   88,   89,   89,   89,   89,   89,   89,
812
       89,   89,   89,   89,   90,    0,    0,    0,    0,    0,
813
        0,   90,    0,   90,   91,   91,   91,   91,   91,   91,
814
       91,   91,   91,   91,   92,    0,    0,    0,    0,    0,
815
       92,   92,   92,   92,   93,    0,    0,    0,    0,    0,
816
       93,   93,   93,   94,   94,   95,   95,   95,    0,   95,
817
        0,   95,   95,   95,   96,   96,   96,   96,   96,   96,
818
       96,   96,   96,   96,   97,   97,    0,    0,   97,   97,
819
       97,   97,   97,   97,   98,   98,   98,   98,   98,   98,
820
       98,   98,   98,   98,   99,    0,    0,    0,    0,    0,
821
822
        0,    0,    0,   99,  100,  100,    0,    0,  100,  100,
823
      100,  100,  100,  100,  101,  101,  101,  101,  101,  101,
824
      101,  101,  101,  101,  102,  102,  102,  102,  102,  102,
825
      102,  102,    0,  102,   84,   84,   84,   84,   84,   84,
826
       84,   84,   84,   84,   84,   84,   84,   84,   84,   84,
827
       84,   84,   84,   84,   84,   84,   84,   84
828
    } ;
829
830
/* Table of booleans, true if rule could match eol. */
831
static const flex_int32_t yy_rule_can_match_eol[40] =
832
    {   0,
833
0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 
834
    0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 
835
        };
836
837
static const flex_int16_t yy_rule_linenum[39] =
838
    {   0,
839
       72,   73,   74,   76,   77,   79,   80,   82,   87,   92,
840
       97,  102,  108,  109,  110,  112,  114,  119,  126,  127,
841
      129,  150,  156,  163,  166,  186,  189,  192,  195,  201,
842
      202,  204,  224,  225,  226,  227,  228,  229
843
    } ;
844
845
/* The intent behind this definition is that it'll catch
846
 * any uses of REJECT which flex missed.
847
 */
848
#define REJECT reject_used_but_not_detected
849
#define yymore() yymore_used_but_not_detected
850
0
#define YY_MORE_ADJ 0
851
#define YY_RESTORE_YY_MORE_OFFSET
852
#line 1 "settings/settings_lexer.l"
853
#line 2 "settings/settings_lexer.l"
854
/*
855
 * Copyright (C) 2014-2018 Tobias Brunner
856
 *
857
 * Copyright (C) secunet Security Networks AG
858
 *
859
 * This program is free software; you can redistribute it and/or modify it
860
 * under the terms of the GNU General Public License as published by the
861
 * Free Software Foundation; either version 2 of the License, or (at your
862
 * option) any later version.  See <http://www.fsf.org/copyleft/gpl.txt>.
863
 *
864
 * This program is distributed in the hope that it will be useful, but
865
 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
866
 * or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
867
 * for more details.
868
 */
869
870
#include <utils/parser_helper.h>
871
872
#include "settings_parser.h"
873
874
bool settings_parser_open_next_file(parser_helper_t *ctx);
875
876
static void include_files(parser_helper_t *ctx);
877
878
#line 879 "settings/settings_lexer.c"
879
/* use start conditions stack */
880
/* do not declare unneeded functions */
881
#define YY_NO_INPUT 1
882
/* do not include unistd.h as it might conflict with our scanner states */
883
#define YY_NO_UNISTD_H 1
884
/* due to that disable interactive mode, which requires isatty() */
885
/* don't use global variables */
886
/* maintain the line number */
887
/* don't generate a default rule */
888
/* prefix function/variable declarations */
889
/* don't change the name of the output file otherwise autotools has issues */
890
/* type of our extra data */
891
/* state used to scan references */
892
893
/* state used to scan values */
894
895
/* state used to scan include file patterns */
896
897
/* state used to scan quoted strings */
898
899
/* pattern for section/key names */
900
#line 901 "settings/settings_lexer.c"
901
902
#define INITIAL 0
903
0
#define ref 1
904
0
#define val 2
905
0
#define inc 3
906
0
#define str 4
907
908
#ifndef YY_NO_UNISTD_H
909
/* Special case for "unistd.h", since it is non-ANSI. We include it way
910
 * down here because we want the user's section 1 to have been scanned first.
911
 * The user has a chance to override it with an option.
912
 */
913
/* %if-c-only */
914
#include <unistd.h>
915
/* %endif */
916
/* %if-c++-only */
917
/* %endif */
918
#endif
919
920
#define YY_EXTRA_TYPE parser_helper_t*
921
922
/* %if-c-only Reentrant structure and macros (non-C++). */
923
/* %if-reentrant */
924
925
/* Holds the entire state of the reentrant scanner. */
926
struct yyguts_t
927
    {
928
929
    /* User-defined. Not touched by flex. */
930
    YY_EXTRA_TYPE yyextra_r;
931
932
    /* The rest are the same as the globals declared in the non-reentrant scanner. */
933
    FILE *yyin_r, *yyout_r;
934
    size_t yy_buffer_stack_top; /**< index of top of stack. */
935
    size_t yy_buffer_stack_max; /**< capacity of stack. */
936
    YY_BUFFER_STATE * yy_buffer_stack; /**< Stack as an array. */
937
    char yy_hold_char;
938
    int yy_n_chars;
939
    int yyleng_r;
940
    char *yy_c_buf_p;
941
    int yy_init;
942
    int yy_start;
943
    int yy_did_buffer_switch_on_eof;
944
    int yy_start_stack_ptr;
945
    int yy_start_stack_depth;
946
    int *yy_start_stack;
947
    yy_state_type yy_last_accepting_state;
948
    char* yy_last_accepting_cpos;
949
950
    int yylineno_r;
951
    int yy_flex_debug_r;
952
953
    char *yytext_r;
954
    int yy_more_flag;
955
    int yy_more_len;
956
957
    }; /* end struct yyguts_t */
958
959
/* %if-c-only */
960
961
static int yy_init_globals ( yyscan_t yyscanner );
962
963
/* %endif */
964
965
/* %if-reentrant */
966
967
int yylex_init (yyscan_t* scanner);
968
969
int yylex_init_extra ( YY_EXTRA_TYPE user_defined, yyscan_t* scanner);
970
971
/* %endif */
972
973
/* %endif End reentrant structures and macros. */
974
975
/* Accessor methods to globals.
976
   These are made visible to non-reentrant scanners for convenience. */
977
978
int yylex_destroy ( yyscan_t yyscanner );
979
980
int yyget_debug ( yyscan_t yyscanner );
981
982
void yyset_debug ( int debug_flag , yyscan_t yyscanner );
983
984
YY_EXTRA_TYPE yyget_extra ( yyscan_t yyscanner );
985
986
void yyset_extra ( YY_EXTRA_TYPE user_defined , yyscan_t yyscanner );
987
988
FILE *yyget_in ( yyscan_t yyscanner );
989
990
void yyset_in  ( FILE * _in_str , yyscan_t yyscanner );
991
992
FILE *yyget_out ( yyscan_t yyscanner );
993
994
void yyset_out  ( FILE * _out_str , yyscan_t yyscanner );
995
996
      int yyget_leng ( yyscan_t yyscanner );
997
998
char *yyget_text ( yyscan_t yyscanner );
999
1000
int yyget_lineno ( yyscan_t yyscanner );
1001
1002
void yyset_lineno ( int _line_number , yyscan_t yyscanner );
1003
1004
int yyget_column  ( yyscan_t yyscanner );
1005
1006
void yyset_column ( int _column_no , yyscan_t yyscanner );
1007
1008
/* %if-bison-bridge */
1009
/* %endif */
1010
1011
/* Macros after this point can all be overridden by user definitions in
1012
 * section 1.
1013
 */
1014
1015
#ifndef YY_SKIP_YYWRAP
1016
#ifdef __cplusplus
1017
extern "C" int yywrap ( yyscan_t yyscanner );
1018
#else
1019
extern int yywrap ( yyscan_t yyscanner );
1020
#endif
1021
#endif
1022
1023
/* %not-for-header */
1024
#ifndef YY_NO_UNPUT
1025
    
1026
    static void yyunput ( int c, char *buf_ptr  , yyscan_t yyscanner);
1027
    
1028
#endif
1029
/* %ok-for-header */
1030
1031
/* %endif */
1032
1033
#ifndef yytext_ptr
1034
static void yy_flex_strncpy ( char *, const char *, int , yyscan_t yyscanner);
1035
#endif
1036
1037
#ifdef YY_NEED_STRLEN
1038
static int yy_flex_strlen ( const char * , yyscan_t yyscanner);
1039
#endif
1040
1041
#ifndef YY_NO_INPUT
1042
/* %if-c-only Standard (non-C++) definition */
1043
/* %not-for-header */
1044
#ifdef __cplusplus
1045
static int yyinput ( yyscan_t yyscanner );
1046
#else
1047
static int input ( yyscan_t yyscanner );
1048
#endif
1049
/* %ok-for-header */
1050
1051
/* %endif */
1052
#endif
1053
1054
/* %if-c-only */
1055
1056
    static void yy_push_state ( int _new_state , yyscan_t yyscanner);
1057
    
1058
    static void yy_pop_state ( yyscan_t yyscanner );
1059
    
1060
    static int yy_top_state ( yyscan_t yyscanner );
1061
    
1062
/* %endif */
1063
1064
/* Amount of stuff to slurp up with each read. */
1065
#ifndef YY_READ_BUF_SIZE
1066
#ifdef __ia64__
1067
/* On IA-64, the buffer size is 16k, not 8k */
1068
#define YY_READ_BUF_SIZE 16384
1069
#else
1070
0
#define YY_READ_BUF_SIZE 8192
1071
#endif /* __ia64__ */
1072
#endif
1073
1074
/* Copy whatever the last rule matched to the standard output. */
1075
#ifndef ECHO
1076
/* %if-c-only Standard (non-C++) definition */
1077
/* This used to be an fputs(), but since the string might contain NUL's,
1078
 * we now use fwrite().
1079
 */
1080
#define ECHO do { if (fwrite( yytext, (size_t) yyleng, 1, yyout )) {} } while (0)
1081
/* %endif */
1082
/* %if-c++-only C++ definition */
1083
/* %endif */
1084
#endif
1085
1086
/* Gets input and stuffs it into "buf".  number of characters read, or YY_NULL,
1087
 * is returned in "result".
1088
 */
1089
#ifndef YY_INPUT
1090
#define YY_INPUT(buf,result,max_size) \
1091
/* %% [5.0] fread()/read() definition of YY_INPUT goes here unless we're doing C++ \ */\
1092
0
  if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
1093
0
    { \
1094
0
    int c = '*'; \
1095
0
    int n; \
1096
0
    for ( n = 0; n < max_size && \
1097
0
           (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
1098
0
      buf[n] = (char) c; \
1099
0
    if ( c == '\n' ) \
1100
0
      buf[n++] = (char) c; \
1101
0
    if ( c == EOF && ferror( yyin ) ) \
1102
0
      YY_FATAL_ERROR( "input in flex scanner failed" ); \
1103
0
    result = n; \
1104
0
    } \
1105
0
  else \
1106
0
    { \
1107
0
    errno=0; \
1108
0
    while ( (result = (int) fread(buf, 1, (yy_size_t) max_size, yyin)) == 0 && ferror(yyin)) \
1109
0
      { \
1110
0
      if( errno != EINTR) \
1111
0
        { \
1112
0
        YY_FATAL_ERROR( "input in flex scanner failed" ); \
1113
0
        break; \
1114
0
        } \
1115
0
      errno=0; \
1116
0
      clearerr(yyin); \
1117
0
      } \
1118
0
    }\
1119
\
1120
/* %if-c++-only C++ definition \ */\
1121
/* %endif */
1122
1123
#endif
1124
1125
/* No semi-colon after return; correct usage is to write "yyterminate();" -
1126
 * we don't want an extra ';' after the "return" because that will cause
1127
 * some compilers to complain about unreachable statements.
1128
 */
1129
#ifndef yyterminate
1130
0
#define yyterminate() return YY_NULL
1131
#endif
1132
1133
/* Number of entries by which start-condition stack grows. */
1134
#ifndef YY_START_STACK_INCR
1135
0
#define YY_START_STACK_INCR 25
1136
#endif
1137
1138
/* Report a fatal error. */
1139
#ifndef YY_FATAL_ERROR
1140
/* %if-c-only */
1141
0
#define YY_FATAL_ERROR(msg) yy_fatal_error( msg , yyscanner)
1142
/* %endif */
1143
/* %if-c++-only */
1144
/* %endif */
1145
#endif
1146
1147
/* %if-tables-serialization structures and prototypes */
1148
/* %not-for-header */
1149
/* %ok-for-header */
1150
1151
/* %not-for-header */
1152
/* %tables-yydmap generated elements */
1153
/* %endif */
1154
/* end tables serialization structures and prototypes */
1155
1156
/* %ok-for-header */
1157
1158
/* Default declaration of generated scanner - a define so the user can
1159
 * easily add parameters.
1160
 */
1161
#ifndef YY_DECL
1162
#define YY_DECL_IS_OURS 1
1163
/* %if-c-only Standard (non-C++) definition */
1164
1165
extern int yylex (yyscan_t yyscanner);
1166
1167
#define YY_DECL int yylex (yyscan_t yyscanner)
1168
/* %endif */
1169
/* %if-c++-only C++ definition */
1170
/* %endif */
1171
#endif /* !YY_DECL */
1172
1173
/* Code executed at the beginning of each rule, after yytext and yyleng
1174
 * have been set up.
1175
 */
1176
#ifndef YY_USER_ACTION
1177
#define YY_USER_ACTION
1178
#endif
1179
1180
/* Code executed at the end of each rule. */
1181
#ifndef YY_BREAK
1182
0
#define YY_BREAK /*LINTED*/break;
1183
#endif
1184
1185
/* %% [6.0] YY_RULE_SETUP definition goes here */
1186
#define YY_RULE_SETUP \
1187
  YY_USER_ACTION
1188
1189
/* %not-for-header */
1190
/** The main scanner function which does all the work.
1191
 */
1192
YY_DECL
1193
0
{
1194
0
  yy_state_type yy_current_state;
1195
0
  char *yy_cp, *yy_bp;
1196
0
  int yy_act;
1197
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
1198
1199
0
  if ( !yyg->yy_init )
1200
0
    {
1201
0
    yyg->yy_init = 1;
1202
1203
#ifdef YY_USER_INIT
1204
    YY_USER_INIT;
1205
#endif
1206
1207
0
    if ( ! yyg->yy_start )
1208
0
      yyg->yy_start = 1; /* first start state */
1209
1210
0
    if ( ! yyin )
1211
/* %if-c-only */
1212
0
      yyin = stdin;
1213
/* %endif */
1214
/* %if-c++-only */
1215
/* %endif */
1216
1217
0
    if ( ! yyout )
1218
/* %if-c-only */
1219
0
      yyout = stdout;
1220
/* %endif */
1221
/* %if-c++-only */
1222
/* %endif */
1223
1224
0
    if ( ! YY_CURRENT_BUFFER ) {
1225
0
      yyensure_buffer_stack (yyscanner);
1226
0
      YY_CURRENT_BUFFER_LVALUE =
1227
0
        yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner);
1228
0
    }
1229
1230
0
    yy_load_buffer_state( yyscanner );
1231
0
    }
1232
1233
0
  {
1234
/* %% [7.0] user's declarations go here */
1235
0
#line 70 "settings/settings_lexer.l"
1236
1237
1238
0
#line 1239 "settings/settings_lexer.c"
1239
1240
0
  while ( /*CONSTCOND*/1 )    /* loops until end-of-file is reached */
1241
0
    {
1242
/* %% [8.0] yymore()-related code goes here */
1243
0
    yy_cp = yyg->yy_c_buf_p;
1244
1245
    /* Support of yytext. */
1246
0
    *yy_cp = yyg->yy_hold_char;
1247
1248
    /* yy_bp points to the position in yy_ch_buf of the start of
1249
     * the current run.
1250
     */
1251
0
    yy_bp = yy_cp;
1252
1253
/* %% [9.0] code to set up and find next match goes here */
1254
0
    yy_current_state = yyg->yy_start;
1255
0
yy_match:
1256
0
    do
1257
0
      {
1258
0
      YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)] ;
1259
0
      if ( yy_accept[yy_current_state] )
1260
0
        {
1261
0
        yyg->yy_last_accepting_state = yy_current_state;
1262
0
        yyg->yy_last_accepting_cpos = yy_cp;
1263
0
        }
1264
0
      while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
1265
0
        {
1266
0
        yy_current_state = (int) yy_def[yy_current_state];
1267
0
        if ( yy_current_state >= 85 )
1268
0
          yy_c = yy_meta[yy_c];
1269
0
        }
1270
0
      yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
1271
0
      ++yy_cp;
1272
0
      }
1273
0
    while ( yy_current_state != 84 );
1274
0
    yy_cp = yyg->yy_last_accepting_cpos;
1275
0
    yy_current_state = yyg->yy_last_accepting_state;
1276
1277
0
yy_find_action:
1278
/* %% [10.0] code to find the action number goes here */
1279
0
    yy_act = yy_accept[yy_current_state];
1280
1281
0
    YY_DO_BEFORE_ACTION;
1282
1283
/* %% [11.0] code for yylineno update goes here */
1284
1285
0
    if ( yy_act != YY_END_OF_BUFFER && yy_rule_can_match_eol[yy_act] )
1286
0
      {
1287
0
      int yyl;
1288
0
      for ( yyl = 0; yyl < yyleng; ++yyl )
1289
0
        if ( yytext[yyl] == '\n' )
1290
          
1291
0
    do{ yylineno++;
1292
0
        yycolumn=0;
1293
0
    }while(0)
1294
0
;
1295
0
      }
1296
1297
0
do_action:  /* This label is used only to access EOF actions. */
1298
1299
/* %% [12.0] debug code goes here */
1300
0
    if ( yy_flex_debug )
1301
0
      {
1302
0
      if ( yy_act == 0 )
1303
0
        fprintf( stderr, "--scanner backing up\n" );
1304
0
      else if ( yy_act < 39 )
1305
0
        fprintf( stderr, "--accepting rule at line %ld (\"%s\")\n",
1306
0
                 (long)yy_rule_linenum[yy_act], yytext );
1307
0
      else if ( yy_act == 39 )
1308
0
        fprintf( stderr, "--accepting default rule (\"%s\")\n",
1309
0
                 yytext );
1310
0
      else if ( yy_act == 40 )
1311
0
        fprintf( stderr, "--(end of buffer or a NUL)\n" );
1312
0
      else
1313
0
        fprintf( stderr, "--EOF (start condition %d)\n", YY_START );
1314
0
      }
1315
1316
0
    switch ( yy_act )
1317
0
  { /* beginning of action switch */
1318
/* %% [13.0] actions go here */
1319
0
      case 0: /* must back up */
1320
      /* undo the effects of YY_DO_BEFORE_ACTION */
1321
0
      *yy_cp = yyg->yy_hold_char;
1322
0
      yy_cp = yyg->yy_last_accepting_cpos;
1323
0
      yy_current_state = yyg->yy_last_accepting_state;
1324
0
      goto yy_find_action;
1325
1326
0
case 1:
1327
0
YY_RULE_SETUP
1328
0
#line 72 "settings/settings_lexer.l"
1329
/* eat comments */
1330
0
  YY_BREAK
1331
0
case 2:
1332
0
YY_RULE_SETUP
1333
0
#line 73 "settings/settings_lexer.l"
1334
/* eat whitespace */
1335
0
  YY_BREAK
1336
0
case 3:
1337
/* rule 3 can match eol */
1338
0
YY_RULE_SETUP
1339
0
#line 74 "settings/settings_lexer.l"
1340
/* eat newlines and comments at the end of a line */
1341
0
  YY_BREAK
1342
0
case 4:
1343
0
#line 77 "settings/settings_lexer.l"
1344
0
case 5:
1345
0
YY_RULE_SETUP
1346
0
#line 77 "settings/settings_lexer.l"
1347
0
return yytext[0];
1348
0
  YY_BREAK
1349
0
case 6:
1350
0
YY_RULE_SETUP
1351
0
#line 79 "settings/settings_lexer.l"
1352
0
return DOT;
1353
0
  YY_BREAK
1354
0
case 7:
1355
0
YY_RULE_SETUP
1356
0
#line 80 "settings/settings_lexer.l"
1357
0
return COMMA;
1358
0
  YY_BREAK
1359
0
case 8:
1360
0
YY_RULE_SETUP
1361
0
#line 82 "settings/settings_lexer.l"
1362
0
{
1363
0
  yy_push_state(ref, yyscanner);
1364
0
  return COLON;
1365
0
}
1366
0
  YY_BREAK
1367
0
case 9:
1368
0
YY_RULE_SETUP
1369
0
#line 87 "settings/settings_lexer.l"
1370
0
{
1371
0
  yy_push_state(val, yyscanner);
1372
0
  return yytext[0];
1373
0
}
1374
0
  YY_BREAK
1375
0
case 10:
1376
/* rule 10 can match eol */
1377
0
*yy_cp = yyg->yy_hold_char; /* undo effects of setting up yytext */
1378
0
YY_LINENO_REWIND_TO(yy_cp - 1);
1379
0
yyg->yy_c_buf_p = yy_cp -= 1;
1380
0
YY_DO_BEFORE_ACTION; /* set up yytext again */
1381
0
YY_RULE_SETUP
1382
0
#line 92 "settings/settings_lexer.l"
1383
0
{
1384
0
  yyextra->string_init(yyextra);
1385
0
  yy_push_state(inc, yyscanner);
1386
0
}
1387
0
  YY_BREAK
1388
0
case 11:
1389
0
YY_RULE_SETUP
1390
0
#line 97 "settings/settings_lexer.l"
1391
0
{
1392
0
  PARSER_DBG1(yyextra, "unexpected string detected");
1393
0
  return STRING_ERROR;
1394
0
}
1395
0
  YY_BREAK
1396
0
case 12:
1397
0
YY_RULE_SETUP
1398
0
#line 102 "settings/settings_lexer.l"
1399
0
{
1400
0
  yylval->s = strdup(yytext);
1401
0
  return NAME;
1402
0
}
1403
0
  YY_BREAK
1404
1405
0
case 13:
1406
0
YY_RULE_SETUP
1407
0
#line 108 "settings/settings_lexer.l"
1408
/* eat comments */
1409
0
  YY_BREAK
1410
0
case 14:
1411
0
YY_RULE_SETUP
1412
0
#line 109 "settings/settings_lexer.l"
1413
/* eat whitespace */
1414
0
  YY_BREAK
1415
0
case 15:
1416
/* rule 15 can match eol */
1417
0
YY_RULE_SETUP
1418
0
#line 110 "settings/settings_lexer.l"
1419
/* eat newlines and comments at the end of a line */
1420
0
  YY_BREAK
1421
0
case 16:
1422
0
YY_RULE_SETUP
1423
0
#line 112 "settings/settings_lexer.l"
1424
0
return COMMA;
1425
0
  YY_BREAK
1426
0
case 17:
1427
0
YY_RULE_SETUP
1428
0
#line 114 "settings/settings_lexer.l"
1429
0
{
1430
0
    yylval->s = strdup(yytext);
1431
0
    return NAME;
1432
0
  }
1433
0
  YY_BREAK
1434
0
case 18:
1435
0
YY_RULE_SETUP
1436
0
#line 119 "settings/settings_lexer.l"
1437
0
{
1438
0
    unput(yytext[0]);
1439
0
    yy_pop_state(yyscanner);
1440
0
  }
1441
0
  YY_BREAK
1442
1443
1444
0
case 19:
1445
0
YY_RULE_SETUP
1446
0
#line 126 "settings/settings_lexer.l"
1447
/* just ignore these */
1448
0
  YY_BREAK
1449
0
case 20:
1450
0
YY_RULE_SETUP
1451
0
#line 127 "settings/settings_lexer.l"
1452
1453
0
  YY_BREAK
1454
0
case YY_STATE_EOF(val):
1455
0
#line 128 "settings/settings_lexer.l"
1456
0
case 21:
1457
/* rule 21 can match eol */
1458
0
YY_RULE_SETUP
1459
0
#line 129 "settings/settings_lexer.l"
1460
0
{
1461
0
    if (*yytext)
1462
0
    {
1463
0
      switch (yytext[0])
1464
0
      {
1465
0
        case '\n':
1466
          /* put the newline back to fix the line numbers */
1467
0
          unput('\n');
1468
0
          yy_set_bol(0);
1469
0
          break;
1470
0
        case '#':
1471
0
        case '}':
1472
          /* these are parsed outside of this start condition */
1473
0
          unput(yytext[0]);
1474
0
          break;
1475
0
      }
1476
0
    }
1477
0
    yy_pop_state(yyscanner);
1478
0
    return NEWLINE;
1479
0
  }
1480
0
  YY_BREAK
1481
0
case 22:
1482
0
YY_RULE_SETUP
1483
0
#line 150 "settings/settings_lexer.l"
1484
0
{
1485
0
    yyextra->string_init(yyextra);
1486
0
    yy_push_state(str, yyscanner);
1487
0
  }
1488
0
  YY_BREAK
1489
/* same as above, but allow more characters */
1490
0
case 23:
1491
0
YY_RULE_SETUP
1492
0
#line 156 "settings/settings_lexer.l"
1493
0
{
1494
0
    yylval->s = strdup(yytext);
1495
0
    return NAME;
1496
0
  }
1497
0
  YY_BREAK
1498
1499
1500
0
case 24:
1501
0
YY_RULE_SETUP
1502
0
#line 163 "settings/settings_lexer.l"
1503
/* just ignore these */
1504
0
  YY_BREAK
1505
/* we allow all characters except #, } and spaces, they can be escaped */
1506
0
case YY_STATE_EOF(inc):
1507
0
#line 165 "settings/settings_lexer.l"
1508
0
case 25:
1509
/* rule 25 can match eol */
1510
0
YY_RULE_SETUP
1511
0
#line 166 "settings/settings_lexer.l"
1512
0
{
1513
0
    if (*yytext)
1514
0
    {
1515
0
      switch (yytext[0])
1516
0
      {
1517
0
        case '\n':
1518
          /* put the newline back to fix the line numbers */
1519
0
          unput('\n');
1520
0
          yy_set_bol(0);
1521
0
          break;
1522
0
        case '#':
1523
0
        case '}':
1524
          /* these are parsed outside of this start condition */
1525
0
          unput(yytext[0]);
1526
0
          break;
1527
0
      }
1528
0
    }
1529
0
    include_files(yyextra);
1530
0
    yy_pop_state(yyscanner);
1531
0
  }
1532
0
  YY_BREAK
1533
0
case 26:
1534
0
YY_RULE_SETUP
1535
0
#line 186 "settings/settings_lexer.l"
1536
0
{ /* string include */
1537
0
    yy_push_state(str, yyscanner);
1538
0
  }
1539
0
  YY_BREAK
1540
0
case 27:
1541
0
YY_RULE_SETUP
1542
0
#line 189 "settings/settings_lexer.l"
1543
0
{
1544
0
    yyextra->string_add(yyextra, yytext);
1545
0
  }
1546
0
  YY_BREAK
1547
0
case 28:
1548
0
YY_RULE_SETUP
1549
0
#line 192 "settings/settings_lexer.l"
1550
0
{
1551
0
    yyextra->string_add(yyextra, yytext+1);
1552
0
  }
1553
0
  YY_BREAK
1554
0
case 29:
1555
0
YY_RULE_SETUP
1556
0
#line 195 "settings/settings_lexer.l"
1557
0
{
1558
0
    yyextra->string_add(yyextra, yytext);
1559
0
  }
1560
0
  YY_BREAK
1561
1562
1563
0
case 30:
1564
0
YY_RULE_SETUP
1565
0
#line 201 "settings/settings_lexer.l"
1566
/* just ignore these */
1567
0
  YY_BREAK
1568
0
case 31:
1569
0
#line 203 "settings/settings_lexer.l"
1570
0
YY_RULE_SETUP
1571
0
case YY_STATE_EOF(str):
1572
0
#line 203 "settings/settings_lexer.l"
1573
0
case 32:
1574
0
YY_RULE_SETUP
1575
0
#line 204 "settings/settings_lexer.l"
1576
0
{
1577
0
    if (!streq(yytext, "\""))
1578
0
    {
1579
0
      PARSER_DBG1(yyextra, "unterminated string detected");
1580
0
      return STRING_ERROR;
1581
0
    }
1582
0
    if (yy_top_state(yyscanner) == inc)
1583
0
    { /* string include */
1584
0
      include_files(yyextra);
1585
0
      yy_pop_state(yyscanner);
1586
0
      yy_pop_state(yyscanner);
1587
0
    }
1588
0
    else
1589
0
    {
1590
0
      yy_pop_state(yyscanner);
1591
0
      yylval->s = yyextra->string_get(yyextra);
1592
0
      return STRING;
1593
0
    }
1594
0
  }
1595
0
  YY_BREAK
1596
0
case 33:
1597
0
YY_RULE_SETUP
1598
0
#line 224 "settings/settings_lexer.l"
1599
0
yyextra->string_add(yyextra, "\n");
1600
0
  YY_BREAK
1601
0
case 34:
1602
0
YY_RULE_SETUP
1603
0
#line 225 "settings/settings_lexer.l"
1604
0
yyextra->string_add(yyextra, "\r");
1605
0
  YY_BREAK
1606
0
case 35:
1607
0
YY_RULE_SETUP
1608
0
#line 226 "settings/settings_lexer.l"
1609
0
yyextra->string_add(yyextra, "\t");
1610
0
  YY_BREAK
1611
0
case 36:
1612
/* rule 36 can match eol */
1613
0
YY_RULE_SETUP
1614
0
#line 227 "settings/settings_lexer.l"
1615
/* merge lines that end with escaped EOL characters */
1616
0
  YY_BREAK
1617
0
case 37:
1618
0
YY_RULE_SETUP
1619
0
#line 228 "settings/settings_lexer.l"
1620
0
yyextra->string_add(yyextra, yytext+1);
1621
0
  YY_BREAK
1622
0
case 38:
1623
/* rule 38 can match eol */
1624
0
YY_RULE_SETUP
1625
0
#line 229 "settings/settings_lexer.l"
1626
0
{
1627
0
    yyextra->string_add(yyextra, yytext);
1628
0
  }
1629
0
  YY_BREAK
1630
1631
0
case YY_STATE_EOF(INITIAL):
1632
0
case YY_STATE_EOF(ref):
1633
0
#line 234 "settings/settings_lexer.l"
1634
0
{
1635
0
  settings_parser_pop_buffer_state(yyscanner);
1636
0
  if (!settings_parser_open_next_file(yyextra) && !YY_CURRENT_BUFFER)
1637
0
  {
1638
0
    yyterminate();
1639
0
  }
1640
0
}
1641
0
  YY_BREAK
1642
0
case 39:
1643
0
YY_RULE_SETUP
1644
0
#line 242 "settings/settings_lexer.l"
1645
0
YY_FATAL_ERROR( "flex scanner jammed" );
1646
0
  YY_BREAK
1647
0
#line 1648 "settings/settings_lexer.c"
1648
1649
0
  case YY_END_OF_BUFFER:
1650
0
    {
1651
    /* Amount of text matched not including the EOB char. */
1652
0
    int yy_amount_of_matched_text = (int) (yy_cp - yyg->yytext_ptr) - 1;
1653
1654
    /* Undo the effects of YY_DO_BEFORE_ACTION. */
1655
0
    *yy_cp = yyg->yy_hold_char;
1656
0
    YY_RESTORE_YY_MORE_OFFSET
1657
1658
0
    if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
1659
0
      {
1660
      /* We're scanning a new file or input source.  It's
1661
       * possible that this happened because the user
1662
       * just pointed yyin at a new source and called
1663
       * yylex().  If so, then we have to assure
1664
       * consistency between YY_CURRENT_BUFFER and our
1665
       * globals.  Here is the right place to do so, because
1666
       * this is the first action (other than possibly a
1667
       * back-up) that will match for the new input source.
1668
       */
1669
0
      yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
1670
/* %if-c-only */
1671
0
      YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
1672
/* %endif */
1673
/* %if-c++-only */
1674
/* %endif */
1675
0
      YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
1676
0
      }
1677
1678
    /* Note that here we test for yy_c_buf_p "<=" to the position
1679
     * of the first EOB in the buffer, since yy_c_buf_p will
1680
     * already have been incremented past the NUL character
1681
     * (since all states make transitions on EOB to the
1682
     * end-of-buffer state).  Contrast this with the test
1683
     * in input().
1684
     */
1685
0
    if ( yyg->yy_c_buf_p <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
1686
0
      { /* This was really a NUL. */
1687
0
      yy_state_type yy_next_state;
1688
1689
0
      yyg->yy_c_buf_p = yyg->yytext_ptr + yy_amount_of_matched_text;
1690
1691
0
      yy_current_state = yy_get_previous_state( yyscanner );
1692
1693
      /* Okay, we're now positioned to make the NUL
1694
       * transition.  We couldn't have
1695
       * yy_get_previous_state() go ahead and do it
1696
       * for us because it doesn't know how to deal
1697
       * with the possibility of jamming (and we don't
1698
       * want to build jamming into it because then it
1699
       * will run more slowly).
1700
       */
1701
1702
0
      yy_next_state = yy_try_NUL_trans( yy_current_state , yyscanner);
1703
1704
0
      yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
1705
1706
0
      if ( yy_next_state )
1707
0
        {
1708
        /* Consume the NUL. */
1709
0
        yy_cp = ++yyg->yy_c_buf_p;
1710
0
        yy_current_state = yy_next_state;
1711
0
        goto yy_match;
1712
0
        }
1713
1714
0
      else
1715
0
        {
1716
/* %% [14.0] code to do back-up for compressed tables and set up yy_cp goes here */
1717
0
        yy_cp = yyg->yy_last_accepting_cpos;
1718
0
        yy_current_state = yyg->yy_last_accepting_state;
1719
0
        goto yy_find_action;
1720
0
        }
1721
0
      }
1722
1723
0
    else switch ( yy_get_next_buffer( yyscanner ) )
1724
0
      {
1725
0
      case EOB_ACT_END_OF_FILE:
1726
0
        {
1727
0
        yyg->yy_did_buffer_switch_on_eof = 0;
1728
1729
0
        if ( yywrap( yyscanner ) )
1730
0
          {
1731
          /* Note: because we've taken care in
1732
           * yy_get_next_buffer() to have set up
1733
           * yytext, we can now set up
1734
           * yy_c_buf_p so that if some total
1735
           * hoser (like flex itself) wants to
1736
           * call the scanner after we return the
1737
           * YY_NULL, it'll still work - another
1738
           * YY_NULL will get returned.
1739
           */
1740
0
          yyg->yy_c_buf_p = yyg->yytext_ptr + YY_MORE_ADJ;
1741
1742
0
          yy_act = YY_STATE_EOF(YY_START);
1743
0
          goto do_action;
1744
0
          }
1745
1746
0
        else
1747
0
          {
1748
0
          if ( ! yyg->yy_did_buffer_switch_on_eof )
1749
0
            YY_NEW_FILE;
1750
0
          }
1751
0
        break;
1752
0
        }
1753
1754
0
      case EOB_ACT_CONTINUE_SCAN:
1755
0
        yyg->yy_c_buf_p =
1756
0
          yyg->yytext_ptr + yy_amount_of_matched_text;
1757
1758
0
        yy_current_state = yy_get_previous_state( yyscanner );
1759
1760
0
        yy_cp = yyg->yy_c_buf_p;
1761
0
        yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
1762
0
        goto yy_match;
1763
1764
0
      case EOB_ACT_LAST_MATCH:
1765
0
        yyg->yy_c_buf_p =
1766
0
        &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars];
1767
1768
0
        yy_current_state = yy_get_previous_state( yyscanner );
1769
1770
0
        yy_cp = yyg->yy_c_buf_p;
1771
0
        yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
1772
0
        goto yy_find_action;
1773
0
      }
1774
0
    break;
1775
0
    }
1776
1777
0
  default:
1778
0
    YY_FATAL_ERROR(
1779
0
      "fatal flex scanner internal error--no action found" );
1780
0
  } /* end of action switch */
1781
0
    } /* end of scanning one token */
1782
0
  } /* end of user's declarations */
1783
0
} /* end of yylex */
1784
/* %ok-for-header */
1785
1786
/* %if-c++-only */
1787
/* %not-for-header */
1788
/* %ok-for-header */
1789
1790
/* %endif */
1791
1792
/* yy_get_next_buffer - try to read in a new buffer
1793
 *
1794
 * Returns a code representing an action:
1795
 *  EOB_ACT_LAST_MATCH -
1796
 *  EOB_ACT_CONTINUE_SCAN - continue scanning from current position
1797
 *  EOB_ACT_END_OF_FILE - end of file
1798
 */
1799
/* %if-c-only */
1800
static int yy_get_next_buffer (yyscan_t yyscanner)
1801
/* %endif */
1802
/* %if-c++-only */
1803
/* %endif */
1804
0
{
1805
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
1806
0
  char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
1807
0
  char *source = yyg->yytext_ptr;
1808
0
  int number_to_move, i;
1809
0
  int ret_val;
1810
1811
0
  if ( yyg->yy_c_buf_p > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] )
1812
0
    YY_FATAL_ERROR(
1813
0
    "fatal flex scanner internal error--end of buffer missed" );
1814
1815
0
  if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
1816
0
    { /* Don't try to fill the buffer, so this is an EOF. */
1817
0
    if ( yyg->yy_c_buf_p - yyg->yytext_ptr - YY_MORE_ADJ == 1 )
1818
0
      {
1819
      /* We matched a single character, the EOB, so
1820
       * treat this as a final EOF.
1821
       */
1822
0
      return EOB_ACT_END_OF_FILE;
1823
0
      }
1824
1825
0
    else
1826
0
      {
1827
      /* We matched some text prior to the EOB, first
1828
       * process it.
1829
       */
1830
0
      return EOB_ACT_LAST_MATCH;
1831
0
      }
1832
0
    }
1833
1834
  /* Try to read more data. */
1835
1836
  /* First move last chars to start of buffer. */
1837
0
  number_to_move = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr - 1);
1838
1839
0
  for ( i = 0; i < number_to_move; ++i )
1840
0
    *(dest++) = *(source++);
1841
1842
0
  if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
1843
    /* don't do the read, it's not guaranteed to return an EOF,
1844
     * just force an EOF
1845
     */
1846
0
    YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars = 0;
1847
1848
0
  else
1849
0
    {
1850
0
      int num_to_read =
1851
0
      YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
1852
1853
0
    while ( num_to_read <= 0 )
1854
0
      { /* Not enough room in the buffer - grow it. */
1855
1856
      /* just a shorter name for the current buffer */
1857
0
      YY_BUFFER_STATE b = YY_CURRENT_BUFFER_LVALUE;
1858
1859
0
      int yy_c_buf_p_offset =
1860
0
        (int) (yyg->yy_c_buf_p - b->yy_ch_buf);
1861
1862
0
      if ( b->yy_is_our_buffer )
1863
0
        {
1864
0
        int new_size = b->yy_buf_size * 2;
1865
1866
0
        if ( new_size <= 0 )
1867
0
          b->yy_buf_size += b->yy_buf_size / 8;
1868
0
        else
1869
0
          b->yy_buf_size *= 2;
1870
1871
0
        b->yy_ch_buf = (char *)
1872
          /* Include room in for 2 EOB chars. */
1873
0
          yyrealloc( (void *) b->yy_ch_buf,
1874
0
               (yy_size_t) (b->yy_buf_size + 2) , yyscanner );
1875
0
        }
1876
0
      else
1877
        /* Can't grow it, we don't own it. */
1878
0
        b->yy_ch_buf = NULL;
1879
1880
0
      if ( ! b->yy_ch_buf )
1881
0
        YY_FATAL_ERROR(
1882
0
        "fatal error - scanner input buffer overflow" );
1883
1884
0
      yyg->yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
1885
1886
0
      num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size -
1887
0
            number_to_move - 1;
1888
1889
0
      }
1890
1891
0
    if ( num_to_read > YY_READ_BUF_SIZE )
1892
0
      num_to_read = YY_READ_BUF_SIZE;
1893
1894
    /* Read in more data. */
1895
0
    YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
1896
0
      yyg->yy_n_chars, num_to_read );
1897
1898
0
    YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
1899
0
    }
1900
1901
0
  if ( yyg->yy_n_chars == 0 )
1902
0
    {
1903
0
    if ( number_to_move == YY_MORE_ADJ )
1904
0
      {
1905
0
      ret_val = EOB_ACT_END_OF_FILE;
1906
0
      yyrestart( yyin  , yyscanner);
1907
0
      }
1908
1909
0
    else
1910
0
      {
1911
0
      ret_val = EOB_ACT_LAST_MATCH;
1912
0
      YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
1913
0
        YY_BUFFER_EOF_PENDING;
1914
0
      }
1915
0
    }
1916
1917
0
  else
1918
0
    ret_val = EOB_ACT_CONTINUE_SCAN;
1919
1920
0
  if ((yyg->yy_n_chars + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
1921
    /* Extend the array by 50%, plus the number we really need. */
1922
0
    int new_size = yyg->yy_n_chars + number_to_move + (yyg->yy_n_chars >> 1);
1923
0
    YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) yyrealloc(
1924
0
      (void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf, (yy_size_t) new_size , yyscanner );
1925
0
    if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
1926
0
      YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
1927
    /* "- 2" to take care of EOB's */
1928
0
    YY_CURRENT_BUFFER_LVALUE->yy_buf_size = (int) (new_size - 2);
1929
0
  }
1930
1931
0
  yyg->yy_n_chars += number_to_move;
1932
0
  YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] = YY_END_OF_BUFFER_CHAR;
1933
0
  YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
1934
1935
0
  yyg->yytext_ptr = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
1936
1937
0
  return ret_val;
1938
0
}
1939
1940
/* yy_get_previous_state - get the state just before the EOB char was reached */
1941
1942
/* %if-c-only */
1943
/* %not-for-header */
1944
    static yy_state_type yy_get_previous_state (yyscan_t yyscanner)
1945
/* %endif */
1946
/* %if-c++-only */
1947
/* %endif */
1948
0
{
1949
0
  yy_state_type yy_current_state;
1950
0
  char *yy_cp;
1951
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
1952
1953
/* %% [15.0] code to get the start state into yy_current_state goes here */
1954
0
  yy_current_state = yyg->yy_start;
1955
1956
0
  for ( yy_cp = yyg->yytext_ptr + YY_MORE_ADJ; yy_cp < yyg->yy_c_buf_p; ++yy_cp )
1957
0
    {
1958
/* %% [16.0] code to find the next state goes here */
1959
0
    YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
1960
0
    if ( yy_accept[yy_current_state] )
1961
0
      {
1962
0
      yyg->yy_last_accepting_state = yy_current_state;
1963
0
      yyg->yy_last_accepting_cpos = yy_cp;
1964
0
      }
1965
0
    while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
1966
0
      {
1967
0
      yy_current_state = (int) yy_def[yy_current_state];
1968
0
      if ( yy_current_state >= 85 )
1969
0
        yy_c = yy_meta[yy_c];
1970
0
      }
1971
0
    yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
1972
0
    }
1973
1974
0
  return yy_current_state;
1975
0
}
1976
1977
/* yy_try_NUL_trans - try to make a transition on the NUL character
1978
 *
1979
 * synopsis
1980
 *  next_state = yy_try_NUL_trans( current_state );
1981
 */
1982
/* %if-c-only */
1983
    static yy_state_type yy_try_NUL_trans  (yy_state_type yy_current_state , yyscan_t yyscanner)
1984
/* %endif */
1985
/* %if-c++-only */
1986
/* %endif */
1987
0
{
1988
0
  int yy_is_jam;
1989
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* This var may be unused depending upon options. */
1990
/* %% [17.0] code to find the next state, and perhaps do backing up, goes here */
1991
0
  char *yy_cp = yyg->yy_c_buf_p;
1992
1993
0
  YY_CHAR yy_c = 1;
1994
0
  if ( yy_accept[yy_current_state] )
1995
0
    {
1996
0
    yyg->yy_last_accepting_state = yy_current_state;
1997
0
    yyg->yy_last_accepting_cpos = yy_cp;
1998
0
    }
1999
0
  while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
2000
0
    {
2001
0
    yy_current_state = (int) yy_def[yy_current_state];
2002
0
    if ( yy_current_state >= 85 )
2003
0
      yy_c = yy_meta[yy_c];
2004
0
    }
2005
0
  yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
2006
0
  yy_is_jam = (yy_current_state == 84);
2007
2008
0
  (void)yyg;
2009
0
  return yy_is_jam ? 0 : yy_current_state;
2010
0
}
2011
2012
#ifndef YY_NO_UNPUT
2013
/* %if-c-only */
2014
2015
    static void yyunput (int c, char * yy_bp , yyscan_t yyscanner)
2016
/* %endif */
2017
/* %if-c++-only */
2018
/* %endif */
2019
0
{
2020
0
  char *yy_cp;
2021
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2022
2023
0
    yy_cp = yyg->yy_c_buf_p;
2024
2025
  /* undo effects of setting up yytext */
2026
0
  *yy_cp = yyg->yy_hold_char;
2027
2028
0
  if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
2029
0
    { /* need to shift things up to make room */
2030
    /* +2 for EOB chars. */
2031
0
    int number_to_move = yyg->yy_n_chars + 2;
2032
0
    char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[
2033
0
          YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2];
2034
0
    char *source =
2035
0
        &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move];
2036
2037
0
    while ( source > YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
2038
0
      *--dest = *--source;
2039
2040
0
    yy_cp += (int) (dest - source);
2041
0
    yy_bp += (int) (dest - source);
2042
0
    YY_CURRENT_BUFFER_LVALUE->yy_n_chars =
2043
0
      yyg->yy_n_chars = (int) YY_CURRENT_BUFFER_LVALUE->yy_buf_size;
2044
2045
0
    if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
2046
0
      YY_FATAL_ERROR( "flex scanner push-back overflow" );
2047
0
    }
2048
2049
0
  *--yy_cp = (char) c;
2050
2051
/* %% [18.0] update yylineno here */
2052
2053
0
    if ( c == '\n' ){
2054
0
        --yylineno;
2055
0
    }
2056
2057
0
  yyg->yytext_ptr = yy_bp;
2058
0
  yyg->yy_hold_char = *yy_cp;
2059
0
  yyg->yy_c_buf_p = yy_cp;
2060
0
}
2061
/* %if-c-only */
2062
2063
/* %endif */
2064
#endif
2065
2066
/* %if-c-only */
2067
#ifndef YY_NO_INPUT
2068
#ifdef __cplusplus
2069
    static int yyinput (yyscan_t yyscanner)
2070
#else
2071
    static int input  (yyscan_t yyscanner)
2072
#endif
2073
2074
/* %endif */
2075
/* %if-c++-only */
2076
/* %endif */
2077
{
2078
  int c;
2079
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2080
2081
  *yyg->yy_c_buf_p = yyg->yy_hold_char;
2082
2083
  if ( *yyg->yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
2084
    {
2085
    /* yy_c_buf_p now points to the character we want to return.
2086
     * If this occurs *before* the EOB characters, then it's a
2087
     * valid NUL; if not, then we've hit the end of the buffer.
2088
     */
2089
    if ( yyg->yy_c_buf_p < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
2090
      /* This was really a NUL. */
2091
      *yyg->yy_c_buf_p = '\0';
2092
2093
    else
2094
      { /* need more input */
2095
      int offset = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr);
2096
      ++yyg->yy_c_buf_p;
2097
2098
      switch ( yy_get_next_buffer( yyscanner ) )
2099
        {
2100
        case EOB_ACT_LAST_MATCH:
2101
          /* This happens because yy_g_n_b()
2102
           * sees that we've accumulated a
2103
           * token and flags that we need to
2104
           * try matching the token before
2105
           * proceeding.  But for input(),
2106
           * there's no matching to consider.
2107
           * So convert the EOB_ACT_LAST_MATCH
2108
           * to EOB_ACT_END_OF_FILE.
2109
           */
2110
2111
          /* Reset buffer status. */
2112
          yyrestart( yyin , yyscanner);
2113
2114
          /*FALLTHROUGH*/
2115
2116
        case EOB_ACT_END_OF_FILE:
2117
          {
2118
          if ( yywrap( yyscanner ) )
2119
            return 0;
2120
2121
          if ( ! yyg->yy_did_buffer_switch_on_eof )
2122
            YY_NEW_FILE;
2123
#ifdef __cplusplus
2124
          return yyinput(yyscanner);
2125
#else
2126
          return input(yyscanner);
2127
#endif
2128
          }
2129
2130
        case EOB_ACT_CONTINUE_SCAN:
2131
          yyg->yy_c_buf_p = yyg->yytext_ptr + offset;
2132
          break;
2133
        }
2134
      }
2135
    }
2136
2137
  c = *(unsigned char *) yyg->yy_c_buf_p; /* cast for 8-bit char's */
2138
  *yyg->yy_c_buf_p = '\0';  /* preserve yytext */
2139
  yyg->yy_hold_char = *++yyg->yy_c_buf_p;
2140
2141
/* %% [19.0] update BOL and yylineno */
2142
  if ( c == '\n' )
2143
    
2144
    do{ yylineno++;
2145
        yycolumn=0;
2146
    }while(0)
2147
;
2148
2149
  return c;
2150
}
2151
/* %if-c-only */
2152
#endif  /* ifndef YY_NO_INPUT */
2153
/* %endif */
2154
2155
/** Immediately switch to a different input stream.
2156
 * @param input_file A readable stream.
2157
 * @param yyscanner The scanner object.
2158
 * @note This function does not reset the start condition to @c INITIAL .
2159
 */
2160
/* %if-c-only */
2161
    void yyrestart  (FILE * input_file , yyscan_t yyscanner)
2162
/* %endif */
2163
/* %if-c++-only */
2164
/* %endif */
2165
0
{
2166
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2167
2168
0
  if ( ! YY_CURRENT_BUFFER ){
2169
0
        yyensure_buffer_stack (yyscanner);
2170
0
    YY_CURRENT_BUFFER_LVALUE =
2171
0
            yy_create_buffer( yyin, YY_BUF_SIZE , yyscanner);
2172
0
  }
2173
2174
0
  yy_init_buffer( YY_CURRENT_BUFFER, input_file , yyscanner);
2175
0
  yy_load_buffer_state( yyscanner );
2176
0
}
2177
2178
/* %if-c++-only */
2179
/* %endif */
2180
2181
/** Switch to a different input buffer.
2182
 * @param new_buffer The new input buffer.
2183
 * @param yyscanner The scanner object.
2184
 */
2185
/* %if-c-only */
2186
    void yy_switch_to_buffer  (YY_BUFFER_STATE  new_buffer , yyscan_t yyscanner)
2187
/* %endif */
2188
/* %if-c++-only */
2189
/* %endif */
2190
0
{
2191
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2192
2193
  /* TODO. We should be able to replace this entire function body
2194
   * with
2195
   *    yypop_buffer_state();
2196
   *    yypush_buffer_state(new_buffer);
2197
     */
2198
0
  yyensure_buffer_stack (yyscanner);
2199
0
  if ( YY_CURRENT_BUFFER == new_buffer )
2200
0
    return;
2201
2202
0
  if ( YY_CURRENT_BUFFER )
2203
0
    {
2204
    /* Flush out information for old buffer. */
2205
0
    *yyg->yy_c_buf_p = yyg->yy_hold_char;
2206
0
    YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
2207
0
    YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
2208
0
    }
2209
2210
0
  YY_CURRENT_BUFFER_LVALUE = new_buffer;
2211
0
  yy_load_buffer_state( yyscanner );
2212
2213
  /* We don't actually know whether we did this switch during
2214
   * EOF (yywrap()) processing, but the only time this flag
2215
   * is looked at is after yywrap() is called, so it's safe
2216
   * to go ahead and always set it.
2217
   */
2218
0
  yyg->yy_did_buffer_switch_on_eof = 1;
2219
0
}
2220
2221
/* %if-c-only */
2222
static void yy_load_buffer_state  (yyscan_t yyscanner)
2223
/* %endif */
2224
/* %if-c++-only */
2225
/* %endif */
2226
0
{
2227
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2228
0
  yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
2229
0
  yyg->yytext_ptr = yyg->yy_c_buf_p = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
2230
/* %if-c-only */
2231
0
  yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
2232
/* %endif */
2233
/* %if-c++-only */
2234
/* %endif */
2235
0
  yyg->yy_hold_char = *yyg->yy_c_buf_p;
2236
0
}
2237
2238
/** Allocate and initialize an input buffer state.
2239
 * @param file A readable stream.
2240
 * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
2241
 * @param yyscanner The scanner object.
2242
 * @return the allocated buffer state.
2243
 */
2244
/* %if-c-only */
2245
    YY_BUFFER_STATE yy_create_buffer  (FILE * file, int  size , yyscan_t yyscanner)
2246
/* %endif */
2247
/* %if-c++-only */
2248
/* %endif */
2249
0
{
2250
0
  YY_BUFFER_STATE b;
2251
    
2252
0
  b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) , yyscanner );
2253
0
  if ( ! b )
2254
0
    YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
2255
2256
0
  b->yy_buf_size = size;
2257
2258
  /* yy_ch_buf has to be 2 characters longer than the size given because
2259
   * we need to put in 2 end-of-buffer characters.
2260
   */
2261
0
  b->yy_ch_buf = (char *) yyalloc( (yy_size_t) (b->yy_buf_size + 2) , yyscanner );
2262
0
  if ( ! b->yy_ch_buf )
2263
0
    YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
2264
2265
0
  b->yy_is_our_buffer = 1;
2266
2267
0
  yy_init_buffer( b, file , yyscanner);
2268
2269
0
  return b;
2270
0
}
2271
2272
/* %if-c++-only */
2273
/* %endif */
2274
2275
/** Destroy the buffer.
2276
 * @param b a buffer created with yy_create_buffer()
2277
 * @param yyscanner The scanner object.
2278
 */
2279
/* %if-c-only */
2280
    void yy_delete_buffer (YY_BUFFER_STATE  b , yyscan_t yyscanner)
2281
/* %endif */
2282
/* %if-c++-only */
2283
/* %endif */
2284
0
{
2285
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2286
2287
0
  if ( ! b )
2288
0
    return;
2289
2290
0
  if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
2291
0
    YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
2292
2293
0
  if ( b->yy_is_our_buffer )
2294
0
    yyfree( (void *) b->yy_ch_buf , yyscanner );
2295
2296
0
  yyfree( (void *) b , yyscanner );
2297
0
}
2298
2299
/* Initializes or reinitializes a buffer.
2300
 * This function is sometimes called more than once on the same buffer,
2301
 * such as during a yyrestart() or at EOF.
2302
 */
2303
/* %if-c-only */
2304
    static void yy_init_buffer  (YY_BUFFER_STATE  b, FILE * file , yyscan_t yyscanner)
2305
/* %endif */
2306
/* %if-c++-only */
2307
/* %endif */
2308
2309
0
{
2310
0
  int oerrno = errno;
2311
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2312
2313
0
  yy_flush_buffer( b , yyscanner);
2314
2315
/* %if-c-only */
2316
0
  b->yy_input_file = file;
2317
/* %endif */
2318
/* %if-c++-only */
2319
/* %endif */
2320
0
  b->yy_fill_buffer = 1;
2321
2322
    /* If b is the current buffer, then yy_init_buffer was _probably_
2323
     * called from yyrestart() or through yy_get_next_buffer.
2324
     * In that case, we don't want to reset the lineno or column.
2325
     */
2326
0
    if (b != YY_CURRENT_BUFFER){
2327
0
        b->yy_bs_lineno = 1;
2328
0
        b->yy_bs_column = 0;
2329
0
    }
2330
2331
/* %if-c-only */
2332
2333
0
        b->yy_is_interactive = 0;
2334
    
2335
/* %endif */
2336
/* %if-c++-only */
2337
/* %endif */
2338
0
  errno = oerrno;
2339
0
}
2340
2341
/** Discard all buffered characters. On the next scan, YY_INPUT will be called.
2342
 * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
2343
 * @param yyscanner The scanner object.
2344
 */
2345
/* %if-c-only */
2346
    void yy_flush_buffer (YY_BUFFER_STATE  b , yyscan_t yyscanner)
2347
/* %endif */
2348
/* %if-c++-only */
2349
/* %endif */
2350
0
{
2351
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2352
0
  if ( ! b )
2353
0
    return;
2354
2355
0
  b->yy_n_chars = 0;
2356
2357
  /* We always need two end-of-buffer characters.  The first causes
2358
   * a transition to the end-of-buffer state.  The second causes
2359
   * a jam in that state.
2360
   */
2361
0
  b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
2362
0
  b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
2363
2364
0
  b->yy_buf_pos = &b->yy_ch_buf[0];
2365
2366
0
  b->yy_at_bol = 1;
2367
0
  b->yy_buffer_status = YY_BUFFER_NEW;
2368
2369
0
  if ( b == YY_CURRENT_BUFFER )
2370
0
    yy_load_buffer_state( yyscanner );
2371
0
}
2372
2373
/* %if-c-or-c++ */
2374
/** Pushes the new state onto the stack. The new state becomes
2375
 *  the current state. This function will allocate the stack
2376
 *  if necessary.
2377
 *  @param new_buffer The new state.
2378
 *  @param yyscanner The scanner object.
2379
 */
2380
/* %if-c-only */
2381
void yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
2382
/* %endif */
2383
/* %if-c++-only */
2384
/* %endif */
2385
0
{
2386
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2387
0
  if (new_buffer == NULL)
2388
0
    return;
2389
2390
0
  yyensure_buffer_stack(yyscanner);
2391
2392
  /* This block is copied from yy_switch_to_buffer. */
2393
0
  if ( YY_CURRENT_BUFFER )
2394
0
    {
2395
    /* Flush out information for old buffer. */
2396
0
    *yyg->yy_c_buf_p = yyg->yy_hold_char;
2397
0
    YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
2398
0
    YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
2399
0
    }
2400
2401
  /* Only push if top exists. Otherwise, replace top. */
2402
0
  if (YY_CURRENT_BUFFER)
2403
0
    yyg->yy_buffer_stack_top++;
2404
0
  YY_CURRENT_BUFFER_LVALUE = new_buffer;
2405
2406
  /* copied from yy_switch_to_buffer. */
2407
0
  yy_load_buffer_state( yyscanner );
2408
0
  yyg->yy_did_buffer_switch_on_eof = 1;
2409
0
}
2410
/* %endif */
2411
2412
/* %if-c-or-c++ */
2413
/** Removes and deletes the top of the stack, if present.
2414
 *  The next element becomes the new top.
2415
 *  @param yyscanner The scanner object.
2416
 */
2417
/* %if-c-only */
2418
void yypop_buffer_state (yyscan_t yyscanner)
2419
/* %endif */
2420
/* %if-c++-only */
2421
/* %endif */
2422
0
{
2423
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2424
0
  if (!YY_CURRENT_BUFFER)
2425
0
    return;
2426
2427
0
  yy_delete_buffer(YY_CURRENT_BUFFER , yyscanner);
2428
0
  YY_CURRENT_BUFFER_LVALUE = NULL;
2429
0
  if (yyg->yy_buffer_stack_top > 0)
2430
0
    --yyg->yy_buffer_stack_top;
2431
2432
0
  if (YY_CURRENT_BUFFER) {
2433
0
    yy_load_buffer_state( yyscanner );
2434
0
    yyg->yy_did_buffer_switch_on_eof = 1;
2435
0
  }
2436
0
}
2437
/* %endif */
2438
2439
/* %if-c-or-c++ */
2440
/* Allocates the stack if it does not exist.
2441
 *  Guarantees space for at least one push.
2442
 */
2443
/* %if-c-only */
2444
static void yyensure_buffer_stack (yyscan_t yyscanner)
2445
/* %endif */
2446
/* %if-c++-only */
2447
/* %endif */
2448
0
{
2449
0
  yy_size_t num_to_alloc;
2450
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2451
2452
0
  if (!yyg->yy_buffer_stack) {
2453
2454
    /* First allocation is just for 2 elements, since we don't know if this
2455
     * scanner will even need a stack. We use 2 instead of 1 to avoid an
2456
     * immediate realloc on the next call.
2457
         */
2458
0
      num_to_alloc = 1; /* After all that talk, this was set to 1 anyways... */
2459
0
    yyg->yy_buffer_stack = (struct yy_buffer_state**)yyalloc
2460
0
                (num_to_alloc * sizeof(struct yy_buffer_state*)
2461
0
                , yyscanner);
2462
0
    if ( ! yyg->yy_buffer_stack )
2463
0
      YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
2464
2465
0
    memset(yyg->yy_buffer_stack, 0, num_to_alloc * sizeof(struct yy_buffer_state*));
2466
2467
0
    yyg->yy_buffer_stack_max = num_to_alloc;
2468
0
    yyg->yy_buffer_stack_top = 0;
2469
0
    return;
2470
0
  }
2471
2472
0
  if (yyg->yy_buffer_stack_top >= (yyg->yy_buffer_stack_max) - 1){
2473
2474
    /* Increase the buffer to prepare for a possible push. */
2475
0
    yy_size_t grow_size = 8 /* arbitrary grow size */;
2476
2477
0
    num_to_alloc = yyg->yy_buffer_stack_max + grow_size;
2478
0
    yyg->yy_buffer_stack = (struct yy_buffer_state**)yyrealloc
2479
0
                (yyg->yy_buffer_stack,
2480
0
                num_to_alloc * sizeof(struct yy_buffer_state*)
2481
0
                , yyscanner);
2482
0
    if ( ! yyg->yy_buffer_stack )
2483
0
      YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
2484
2485
    /* zero only the new slots.*/
2486
0
    memset(yyg->yy_buffer_stack + yyg->yy_buffer_stack_max, 0, grow_size * sizeof(struct yy_buffer_state*));
2487
0
    yyg->yy_buffer_stack_max = num_to_alloc;
2488
0
  }
2489
0
}
2490
/* %endif */
2491
2492
/* %if-c-only */
2493
/** Setup the input buffer state to scan directly from a user-specified character buffer.
2494
 * @param base the character buffer
2495
 * @param size the size in bytes of the character buffer
2496
 * @param yyscanner The scanner object.
2497
 * @return the newly allocated buffer state object.
2498
 */
2499
YY_BUFFER_STATE yy_scan_buffer  (char * base, yy_size_t  size , yyscan_t yyscanner)
2500
0
{
2501
0
  YY_BUFFER_STATE b;
2502
    
2503
0
  if ( size < 2 ||
2504
0
       base[size-2] != YY_END_OF_BUFFER_CHAR ||
2505
0
       base[size-1] != YY_END_OF_BUFFER_CHAR )
2506
    /* They forgot to leave room for the EOB's. */
2507
0
    return NULL;
2508
2509
0
  b = (YY_BUFFER_STATE) yyalloc( sizeof( struct yy_buffer_state ) , yyscanner );
2510
0
  if ( ! b )
2511
0
    YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
2512
2513
0
  b->yy_buf_size = (int) (size - 2);  /* "- 2" to take care of EOB's */
2514
0
  b->yy_buf_pos = b->yy_ch_buf = base;
2515
0
  b->yy_is_our_buffer = 0;
2516
0
  b->yy_input_file = NULL;
2517
0
  b->yy_n_chars = b->yy_buf_size;
2518
0
  b->yy_is_interactive = 0;
2519
0
  b->yy_at_bol = 1;
2520
0
  b->yy_fill_buffer = 0;
2521
0
  b->yy_buffer_status = YY_BUFFER_NEW;
2522
2523
0
  yy_switch_to_buffer( b , yyscanner );
2524
2525
0
  return b;
2526
0
}
2527
/* %endif */
2528
2529
/* %if-c-only */
2530
/** Setup the input buffer state to scan a string. The next call to yylex() will
2531
 * scan from a @e copy of @a str.
2532
 * @param yystr a NUL-terminated string to scan
2533
 * @param yyscanner The scanner object.
2534
 * @return the newly allocated buffer state object.
2535
 * @note If you want to scan bytes that may contain NUL values, then use
2536
 *       yy_scan_bytes() instead.
2537
 */
2538
YY_BUFFER_STATE yy_scan_string (const char * yystr , yyscan_t yyscanner)
2539
0
{
2540
    
2541
0
  return yy_scan_bytes( yystr, (int) strlen(yystr) , yyscanner);
2542
0
}
2543
/* %endif */
2544
2545
/* %if-c-only */
2546
/** Setup the input buffer state to scan the given bytes. The next call to yylex() will
2547
 * scan from a @e copy of @a bytes.
2548
 * @param yybytes the byte buffer to scan
2549
 * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
2550
 * @param yyscanner The scanner object.
2551
 * @return the newly allocated buffer state object.
2552
 */
2553
YY_BUFFER_STATE yy_scan_bytes  (const char * yybytes, int  _yybytes_len , yyscan_t yyscanner)
2554
0
{
2555
0
  YY_BUFFER_STATE b;
2556
0
  char *buf;
2557
0
  yy_size_t n;
2558
0
  int i;
2559
    
2560
  /* Get memory for full buffer, including space for trailing EOB's. */
2561
0
  n = (yy_size_t) (_yybytes_len + 2);
2562
0
  buf = (char *) yyalloc( n , yyscanner );
2563
0
  if ( ! buf )
2564
0
    YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
2565
2566
0
  for ( i = 0; i < _yybytes_len; ++i )
2567
0
    buf[i] = yybytes[i];
2568
2569
0
  buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
2570
2571
0
  b = yy_scan_buffer( buf, n , yyscanner);
2572
0
  if ( ! b )
2573
0
    YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
2574
2575
  /* It's okay to grow etc. this buffer, and we should throw it
2576
   * away when we're done.
2577
   */
2578
0
  b->yy_is_our_buffer = 1;
2579
2580
0
  return b;
2581
0
}
2582
/* %endif */
2583
2584
/* %if-c-only */
2585
    static void yy_push_state (int  _new_state , yyscan_t yyscanner)
2586
/* %endif */
2587
/* %if-c++-only */
2588
/* %endif */
2589
0
{
2590
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2591
0
  if ( yyg->yy_start_stack_ptr >= yyg->yy_start_stack_depth )
2592
0
    {
2593
0
    yy_size_t new_size;
2594
2595
0
    yyg->yy_start_stack_depth += YY_START_STACK_INCR;
2596
0
    new_size = (yy_size_t) yyg->yy_start_stack_depth * sizeof( int );
2597
2598
0
    if ( ! yyg->yy_start_stack )
2599
0
      yyg->yy_start_stack = (int *) yyalloc( new_size , yyscanner );
2600
2601
0
    else
2602
0
      yyg->yy_start_stack = (int *) yyrealloc(
2603
0
          (void *) yyg->yy_start_stack, new_size , yyscanner );
2604
2605
0
    if ( ! yyg->yy_start_stack )
2606
0
      YY_FATAL_ERROR( "out of memory expanding start-condition stack" );
2607
0
    }
2608
2609
0
  yyg->yy_start_stack[yyg->yy_start_stack_ptr++] = YY_START;
2610
2611
0
  BEGIN(_new_state);
2612
0
}
2613
2614
/* %if-c-only */
2615
    static void yy_pop_state  (yyscan_t yyscanner)
2616
/* %endif */
2617
/* %if-c++-only */
2618
/* %endif */
2619
0
{
2620
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2621
0
  if ( --yyg->yy_start_stack_ptr < 0 )
2622
0
    YY_FATAL_ERROR( "start-condition stack underflow" );
2623
2624
0
  BEGIN(yyg->yy_start_stack[yyg->yy_start_stack_ptr]);
2625
0
}
2626
2627
/* %if-c-only */
2628
    static int yy_top_state  (yyscan_t yyscanner)
2629
/* %endif */
2630
/* %if-c++-only */
2631
/* %endif */
2632
0
{
2633
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2634
0
  return yyg->yy_start_stack[yyg->yy_start_stack_ptr - 1];
2635
0
}
2636
2637
#ifndef YY_EXIT_FAILURE
2638
0
#define YY_EXIT_FAILURE 2
2639
#endif
2640
2641
/* %if-c-only */
2642
static void yynoreturn yy_fatal_error (const char* msg , yyscan_t yyscanner)
2643
0
{
2644
0
  struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2645
0
  (void)yyg;
2646
0
  fprintf( stderr, "%s\n", msg );
2647
0
  exit( YY_EXIT_FAILURE );
2648
0
}
2649
/* %endif */
2650
/* %if-c++-only */
2651
/* %endif */
2652
2653
/* Redefine yyless() so it works in section 3 code. */
2654
2655
#undef yyless
2656
#define yyless(n) \
2657
  do \
2658
    { \
2659
    /* Undo effects of setting up yytext. */ \
2660
        int yyless_macro_arg = (n); \
2661
        YY_LESS_LINENO(yyless_macro_arg);\
2662
    yytext[yyleng] = yyg->yy_hold_char; \
2663
    yyg->yy_c_buf_p = yytext + yyless_macro_arg; \
2664
    yyg->yy_hold_char = *yyg->yy_c_buf_p; \
2665
    *yyg->yy_c_buf_p = '\0'; \
2666
    yyleng = yyless_macro_arg; \
2667
    } \
2668
  while ( 0 )
2669
2670
/* Accessor  methods (get/set functions) to struct members. */
2671
2672
/* %if-c-only */
2673
/* %if-reentrant */
2674
2675
/** Get the user-defined data for this scanner.
2676
 * @param yyscanner The scanner object.
2677
 */
2678
YY_EXTRA_TYPE yyget_extra  (yyscan_t yyscanner)
2679
0
{
2680
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2681
0
    return yyextra;
2682
0
}
2683
2684
/* %endif */
2685
2686
/** Get the current line number.
2687
 * @param yyscanner The scanner object.
2688
 */
2689
int yyget_lineno  (yyscan_t yyscanner)
2690
0
{
2691
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2692
2693
0
        if (! YY_CURRENT_BUFFER)
2694
0
            return 0;
2695
    
2696
0
    return yylineno;
2697
0
}
2698
2699
/** Get the current column number.
2700
 * @param yyscanner The scanner object.
2701
 */
2702
int yyget_column  (yyscan_t yyscanner)
2703
0
{
2704
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2705
2706
0
        if (! YY_CURRENT_BUFFER)
2707
0
            return 0;
2708
    
2709
0
    return yycolumn;
2710
0
}
2711
2712
/** Get the input stream.
2713
 * @param yyscanner The scanner object.
2714
 */
2715
FILE *yyget_in  (yyscan_t yyscanner)
2716
0
{
2717
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2718
0
    return yyin;
2719
0
}
2720
2721
/** Get the output stream.
2722
 * @param yyscanner The scanner object.
2723
 */
2724
FILE *yyget_out  (yyscan_t yyscanner)
2725
0
{
2726
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2727
0
    return yyout;
2728
0
}
2729
2730
/** Get the length of the current token.
2731
 * @param yyscanner The scanner object.
2732
 */
2733
int yyget_leng  (yyscan_t yyscanner)
2734
0
{
2735
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2736
0
    return yyleng;
2737
0
}
2738
2739
/** Get the current token.
2740
 * @param yyscanner The scanner object.
2741
 */
2742
2743
char *yyget_text  (yyscan_t yyscanner)
2744
0
{
2745
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2746
0
    return yytext;
2747
0
}
2748
2749
/* %if-reentrant */
2750
2751
/** Set the user-defined data. This data is never touched by the scanner.
2752
 * @param user_defined The data to be associated with this scanner.
2753
 * @param yyscanner The scanner object.
2754
 */
2755
void yyset_extra (YY_EXTRA_TYPE  user_defined , yyscan_t yyscanner)
2756
9.78k
{
2757
9.78k
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2758
9.78k
    yyextra = user_defined ;
2759
9.78k
}
2760
2761
/* %endif */
2762
2763
/** Set the current line number.
2764
 * @param _line_number line number
2765
 * @param yyscanner The scanner object.
2766
 */
2767
void yyset_lineno (int  _line_number , yyscan_t yyscanner)
2768
0
{
2769
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2770
2771
        /* lineno is only valid if an input buffer exists. */
2772
0
        if (! YY_CURRENT_BUFFER )
2773
0
           YY_FATAL_ERROR( "yyset_lineno called with no buffer" );
2774
    
2775
0
    yylineno = _line_number;
2776
0
}
2777
2778
/** Set the current column.
2779
 * @param _column_no column number
2780
 * @param yyscanner The scanner object.
2781
 */
2782
void yyset_column (int  _column_no , yyscan_t yyscanner)
2783
0
{
2784
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2785
2786
        /* column is only valid if an input buffer exists. */
2787
0
        if (! YY_CURRENT_BUFFER )
2788
0
           YY_FATAL_ERROR( "yyset_column called with no buffer" );
2789
    
2790
0
    yycolumn = _column_no;
2791
0
}
2792
2793
/** Set the input stream. This does not discard the current
2794
 * input buffer.
2795
 * @param _in_str A readable stream.
2796
 * @param yyscanner The scanner object.
2797
 * @see yy_switch_to_buffer
2798
 */
2799
void yyset_in (FILE *  _in_str , yyscan_t yyscanner)
2800
0
{
2801
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2802
0
    yyin = _in_str ;
2803
0
}
2804
2805
void yyset_out (FILE *  _out_str , yyscan_t yyscanner)
2806
0
{
2807
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2808
0
    yyout = _out_str ;
2809
0
}
2810
2811
int yyget_debug  (yyscan_t yyscanner)
2812
0
{
2813
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2814
0
    return yy_flex_debug;
2815
0
}
2816
2817
void yyset_debug (int  _bdebug , yyscan_t yyscanner)
2818
0
{
2819
0
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2820
0
    yy_flex_debug = _bdebug ;
2821
0
}
2822
2823
/* %endif */
2824
2825
/* %if-reentrant */
2826
/* Accessor methods for yylval and yylloc */
2827
2828
/* %if-bison-bridge */
2829
/* %endif */
2830
2831
/* User-visible API */
2832
2833
/* yylex_init is special because it creates the scanner itself, so it is
2834
 * the ONLY reentrant function that doesn't take the scanner as the last argument.
2835
 * That's why we explicitly handle the declaration, instead of using our macros.
2836
 */
2837
int yylex_init(yyscan_t* ptr_yy_globals)
2838
0
{
2839
0
    if (ptr_yy_globals == NULL){
2840
0
        errno = EINVAL;
2841
0
        return 1;
2842
0
    }
2843
2844
0
    *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), NULL );
2845
2846
0
    if (*ptr_yy_globals == NULL){
2847
0
        errno = ENOMEM;
2848
0
        return 1;
2849
0
    }
2850
2851
    /* By setting to 0xAA, we expose bugs in yy_init_globals. Leave at 0x00 for releases. */
2852
0
    memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
2853
2854
0
    return yy_init_globals ( *ptr_yy_globals );
2855
0
}
2856
2857
/* yylex_init_extra has the same functionality as yylex_init, but follows the
2858
 * convention of taking the scanner as the last argument. Note however, that
2859
 * this is a *pointer* to a scanner, as it will be allocated by this call (and
2860
 * is the reason, too, why this function also must handle its own declaration).
2861
 * The user defined value in the first argument will be available to yyalloc in
2862
 * the yyextra field.
2863
 */
2864
int yylex_init_extra( YY_EXTRA_TYPE yy_user_defined, yyscan_t* ptr_yy_globals )
2865
4.89k
{
2866
4.89k
    struct yyguts_t dummy_yyguts;
2867
2868
4.89k
    yyset_extra (yy_user_defined, &dummy_yyguts);
2869
2870
4.89k
    if (ptr_yy_globals == NULL){
2871
0
        errno = EINVAL;
2872
0
        return 1;
2873
0
    }
2874
2875
4.89k
    *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), &dummy_yyguts );
2876
2877
4.89k
    if (*ptr_yy_globals == NULL){
2878
0
        errno = ENOMEM;
2879
0
        return 1;
2880
0
    }
2881
2882
    /* By setting to 0xAA, we expose bugs in
2883
    yy_init_globals. Leave at 0x00 for releases. */
2884
4.89k
    memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
2885
2886
4.89k
    yyset_extra (yy_user_defined, *ptr_yy_globals);
2887
2888
4.89k
    return yy_init_globals ( *ptr_yy_globals );
2889
4.89k
}
2890
2891
/* %endif if-c-only */
2892
2893
/* %if-c-only */
2894
static int yy_init_globals (yyscan_t yyscanner)
2895
9.78k
{
2896
9.78k
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2897
    /* Initialization is the same as for the non-reentrant scanner.
2898
     * This function is called from yylex_destroy(), so don't allocate here.
2899
     */
2900
2901
9.78k
    yyg->yy_buffer_stack = NULL;
2902
9.78k
    yyg->yy_buffer_stack_top = 0;
2903
9.78k
    yyg->yy_buffer_stack_max = 0;
2904
9.78k
    yyg->yy_c_buf_p = NULL;
2905
9.78k
    yyg->yy_init = 0;
2906
9.78k
    yyg->yy_start = 0;
2907
2908
9.78k
    yyg->yy_start_stack_ptr = 0;
2909
9.78k
    yyg->yy_start_stack_depth = 0;
2910
9.78k
    yyg->yy_start_stack =  NULL;
2911
2912
/* Defined in main.c */
2913
#ifdef YY_STDINIT
2914
    yyin = stdin;
2915
    yyout = stdout;
2916
#else
2917
9.78k
    yyin = NULL;
2918
9.78k
    yyout = NULL;
2919
9.78k
#endif
2920
2921
    /* For future reference: Set errno on error, since we are called by
2922
     * yylex_init()
2923
     */
2924
9.78k
    return 0;
2925
9.78k
}
2926
/* %endif */
2927
2928
/* %if-c-only SNIP! this currently causes conflicts with the c++ scanner */
2929
/* yylex_destroy is for both reentrant and non-reentrant scanners. */
2930
int yylex_destroy  (yyscan_t yyscanner)
2931
4.89k
{
2932
4.89k
    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2933
2934
    /* Pop the buffer stack, destroying each element. */
2935
4.89k
  while(YY_CURRENT_BUFFER){
2936
0
    yy_delete_buffer( YY_CURRENT_BUFFER , yyscanner );
2937
0
    YY_CURRENT_BUFFER_LVALUE = NULL;
2938
0
    yypop_buffer_state(yyscanner);
2939
0
  }
2940
2941
  /* Destroy the stack itself. */
2942
4.89k
  yyfree(yyg->yy_buffer_stack , yyscanner);
2943
4.89k
  yyg->yy_buffer_stack = NULL;
2944
2945
    /* Destroy the start condition stack. */
2946
4.89k
        yyfree( yyg->yy_start_stack , yyscanner );
2947
4.89k
        yyg->yy_start_stack = NULL;
2948
2949
    /* Reset the globals. This is important in a non-reentrant scanner so the next time
2950
     * yylex() is called, initialization will occur. */
2951
4.89k
    yy_init_globals( yyscanner);
2952
2953
/* %if-reentrant */
2954
    /* Destroy the main struct (reentrant only). */
2955
4.89k
    yyfree ( yyscanner , yyscanner );
2956
4.89k
    yyscanner = NULL;
2957
/* %endif */
2958
4.89k
    return 0;
2959
4.89k
}
2960
/* %endif */
2961
2962
/*
2963
 * Internal utility routines.
2964
 */
2965
2966
#ifndef yytext_ptr
2967
static void yy_flex_strncpy (char* s1, const char * s2, int n , yyscan_t yyscanner)
2968
{
2969
  struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2970
  (void)yyg;
2971
2972
  int i;
2973
  for ( i = 0; i < n; ++i )
2974
    s1[i] = s2[i];
2975
}
2976
#endif
2977
2978
#ifdef YY_NEED_STRLEN
2979
static int yy_flex_strlen (const char * s , yyscan_t yyscanner)
2980
{
2981
  int n;
2982
  for ( n = 0; s[n]; ++n )
2983
    ;
2984
2985
  return n;
2986
}
2987
#endif
2988
2989
void *yyalloc (yy_size_t  size , yyscan_t yyscanner)
2990
4.89k
{
2991
4.89k
  struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2992
4.89k
  (void)yyg;
2993
4.89k
  return malloc(size);
2994
4.89k
}
2995
2996
void *yyrealloc  (void * ptr, yy_size_t  size , yyscan_t yyscanner)
2997
0
{
2998
0
  struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
2999
0
  (void)yyg;
3000
3001
  /* The cast to (char *) in the following accommodates both
3002
   * implementations that use char* generic pointers, and those
3003
   * that use void* generic pointers.  It works with the latter
3004
   * because both ANSI C and C++ allow castless assignment from
3005
   * any pointer type to void*, and deal with argument conversions
3006
   * as though doing an assignment.
3007
   */
3008
0
  return realloc(ptr, size);
3009
0
}
3010
3011
void yyfree (void * ptr , yyscan_t yyscanner)
3012
14.6k
{
3013
14.6k
  struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
3014
14.6k
  (void)yyg;
3015
14.6k
  free( (char *) ptr ); /* see yyrealloc() for (char *) cast */
3016
14.6k
}
3017
3018
/* %if-tables-serialization definitions */
3019
/* %define-yytables   The name for this specific scanner's tables. */
3020
#define YYTABLES_NAME "yytables"
3021
/* %endif */
3022
3023
/* %ok-for-header */
3024
3025
#line 242 "settings/settings_lexer.l"
3026
3027
3028
/**
3029
 * Open the next file, if any is queued and readable, otherwise returns FALSE.
3030
 */
3031
bool settings_parser_open_next_file(parser_helper_t *ctx)
3032
4.89k
{
3033
4.89k
  FILE *file;
3034
3035
4.89k
  file = ctx->file_next(ctx);
3036
4.89k
  if (!file)
3037
4.89k
  {
3038
4.89k
    return FALSE;
3039
4.89k
  }
3040
3041
0
  settings_parser_set_in(file, ctx->scanner);
3042
0
  settings_parser_push_buffer_state(
3043
0
      settings_parser__create_buffer(file, YY_BUF_SIZE,
3044
0
                       ctx->scanner), ctx->scanner);
3045
0
  return TRUE;
3046
4.89k
}
3047
3048
/**
3049
 * Assumes that the file pattern to include is currently stored as string on
3050
 * the helper object.
3051
 */
3052
static void include_files(parser_helper_t *ctx)
3053
0
{
3054
0
  char *pattern = ctx->string_get(ctx);
3055
3056
0
  ctx->file_include(ctx, pattern);
3057
0
  free(pattern);
3058
3059
0
  settings_parser_open_next_file(ctx);
3060
0
}
3061
3062
/**
3063
 * Load the given string to be parsed next
3064
 */
3065
void settings_parser_load_string(parser_helper_t *ctx, const char *content)
3066
0
{
3067
0
  settings_parser__scan_string(content, ctx->scanner);
3068
0
}
3069