ael_lex.c

Go to the documentation of this file.
00001 #define WRAP_LIBC_MALLOC
00002 #include "asterisk.h"
00003 
00004 #line 2 "ael_lex.c"
00005 
00006 #line 4 "ael_lex.c"
00007 
00008 #define  YY_INT_ALIGNED short int
00009 
00010 /* A lexical scanner generated by flex */
00011 
00012 #define FLEX_SCANNER
00013 #define YY_FLEX_MAJOR_VERSION 2
00014 #define YY_FLEX_MINOR_VERSION 5
00015 #define YY_FLEX_SUBMINOR_VERSION 35
00016 #if YY_FLEX_SUBMINOR_VERSION > 0
00017 #define FLEX_BETA
00018 #endif
00019 
00020 /* First, we deal with  platform-specific or compiler-specific issues. */
00021 
00022 /* begin standard C headers. */
00023 #include <stdio.h>
00024 #include <string.h>
00025 #include <errno.h>
00026 #include <stdlib.h>
00027 
00028 /* end standard C headers. */
00029 
00030 /* flex integer type definitions */
00031 
00032 #ifndef FLEXINT_H
00033 #define FLEXINT_H
00034 
00035 /* C99 systems have <inttypes.h>. Non-C99 systems may or may not. */
00036 
00037 #if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
00038 
00039 /* C99 says to define __STDC_LIMIT_MACROS before including stdint.h,
00040  * if you want the limit (max/min) macros for int types. 
00041  */
00042 #ifndef __STDC_LIMIT_MACROS
00043 #define __STDC_LIMIT_MACROS 1
00044 #endif
00045 
00046 #include <inttypes.h>
00047 typedef int8_t flex_int8_t;
00048 typedef uint8_t flex_uint8_t;
00049 typedef int16_t flex_int16_t;
00050 typedef uint16_t flex_uint16_t;
00051 typedef int32_t flex_int32_t;
00052 typedef uint32_t flex_uint32_t;
00053 #else
00054 typedef signed char flex_int8_t;
00055 typedef short int flex_int16_t;
00056 typedef int flex_int32_t;
00057 typedef unsigned char flex_uint8_t; 
00058 typedef unsigned short int flex_uint16_t;
00059 typedef unsigned int flex_uint32_t;
00060 
00061 /* Limits of integral types. */
00062 #ifndef INT8_MIN
00063 #define INT8_MIN               (-128)
00064 #endif
00065 #ifndef INT16_MIN
00066 #define INT16_MIN              (-32767-1)
00067 #endif
00068 #ifndef INT32_MIN
00069 #define INT32_MIN              (-2147483647-1)
00070 #endif
00071 #ifndef INT8_MAX
00072 #define INT8_MAX               (127)
00073 #endif
00074 #ifndef INT16_MAX
00075 #define INT16_MAX              (32767)
00076 #endif
00077 #ifndef INT32_MAX
00078 #define INT32_MAX              (2147483647)
00079 #endif
00080 #ifndef UINT8_MAX
00081 #define UINT8_MAX              (255U)
00082 #endif
00083 #ifndef UINT16_MAX
00084 #define UINT16_MAX             (65535U)
00085 #endif
00086 #ifndef UINT32_MAX
00087 #define UINT32_MAX             (4294967295U)
00088 #endif
00089 
00090 #endif /* ! C99 */
00091 
00092 #endif /* ! FLEXINT_H */
00093 
00094 #ifdef __cplusplus
00095 
00096 /* The "const" storage-class-modifier is valid. */
00097 #define YY_USE_CONST
00098 
00099 #else /* ! __cplusplus */
00100 
00101 /* C99 requires __STDC__ to be defined as 1. */
00102 #if defined (__STDC__)
00103 
00104 #define YY_USE_CONST
00105 
00106 #endif   /* defined (__STDC__) */
00107 #endif   /* ! __cplusplus */
00108 
00109 #ifdef YY_USE_CONST
00110 #define yyconst const
00111 #else
00112 #define yyconst
00113 #endif
00114 
00115 /* Returned upon end-of-file. */
00116 #define YY_NULL 0
00117 
00118 /* Promotes a possibly negative, possibly signed char to an unsigned
00119  * integer for use as an array index.  If the signed char is negative,
00120  * we want to instead treat it as an 8-bit unsigned char, hence the
00121  * double cast.
00122  */
00123 #define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
00124 
00125 /* An opaque pointer. */
00126 #ifndef YY_TYPEDEF_YY_SCANNER_T
00127 #define YY_TYPEDEF_YY_SCANNER_T
00128 typedef void* yyscan_t;
00129 #endif
00130 
00131 /* For convenience, these vars (plus the bison vars far below)
00132    are macros in the reentrant scanner. */
00133 #define yyin yyg->yyin_r
00134 #define yyout yyg->yyout_r
00135 #define yyextra yyg->yyextra_r
00136 #define yyleng yyg->yyleng_r
00137 #define yytext yyg->yytext_r
00138 #define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno)
00139 #define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column)
00140 #define yy_flex_debug yyg->yy_flex_debug_r
00141 
00142 /* Enter a start condition.  This macro really ought to take a parameter,
00143  * but we do it the disgusting crufty way forced on us by the ()-less
00144  * definition of BEGIN.
00145  */
00146 #define BEGIN yyg->yy_start = 1 + 2 *
00147 
00148 /* Translate the current start state into a value that can be later handed
00149  * to BEGIN to return to the state.  The YYSTATE alias is for lex
00150  * compatibility.
00151  */
00152 #define YY_START ((yyg->yy_start - 1) / 2)
00153 #define YYSTATE YY_START
00154 
00155 /* Action number for EOF rule of a given start state. */
00156 #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
00157 
00158 /* Special action meaning "start processing a new file". */
00159 #define YY_NEW_FILE ael_yyrestart(yyin ,yyscanner )
00160 
00161 #define YY_END_OF_BUFFER_CHAR 0
00162 
00163 /* Size of default input buffer. */
00164 #ifndef YY_BUF_SIZE
00165 #ifdef __ia64__
00166 /* On IA-64, the buffer size is 16k, not 8k.
00167  * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
00168  * Ditto for the __ia64__ case accordingly.
00169  */
00170 #define YY_BUF_SIZE 32768
00171 #else
00172 #define YY_BUF_SIZE 16384
00173 #endif /* __ia64__ */
00174 #endif
00175 
00176 /* The state buf must be large enough to hold one state per character in the main buffer.
00177  */
00178 #define YY_STATE_BUF_SIZE   ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
00179 
00180 #ifndef YY_TYPEDEF_YY_BUFFER_STATE
00181 #define YY_TYPEDEF_YY_BUFFER_STATE
00182 typedef struct yy_buffer_state *YY_BUFFER_STATE;
00183 #endif
00184 
00185 #define EOB_ACT_CONTINUE_SCAN 0
00186 #define EOB_ACT_END_OF_FILE 1
00187 #define EOB_ACT_LAST_MATCH 2
00188 
00189     #define YY_LESS_LINENO(n)
00190     
00191 /* Return all but the first "n" matched characters back to the input stream. */
00192 #define yyless(n) \
00193    do \
00194       { \
00195       /* Undo effects of setting up yytext. */ \
00196         int yyless_macro_arg = (n); \
00197         YY_LESS_LINENO(yyless_macro_arg);\
00198       *yy_cp = yyg->yy_hold_char; \
00199       YY_RESTORE_YY_MORE_OFFSET \
00200       yyg->yy_c_buf_p = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \
00201       YY_DO_BEFORE_ACTION; /* set up yytext again */ \
00202       } \
00203    while ( 0 )
00204 
00205 #define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner )
00206 
00207 #ifndef YY_TYPEDEF_YY_SIZE_T
00208 #define YY_TYPEDEF_YY_SIZE_T
00209 typedef size_t yy_size_t;
00210 #endif
00211 
00212 #ifndef YY_STRUCT_YY_BUFFER_STATE
00213 #define YY_STRUCT_YY_BUFFER_STATE
00214 struct yy_buffer_state
00215    {
00216    FILE *yy_input_file;
00217 
00218    char *yy_ch_buf;     /* input buffer */
00219    char *yy_buf_pos;    /* current position in input buffer */
00220 
00221    /* Size of input buffer in bytes, not including room for EOB
00222     * characters.
00223     */
00224    yy_size_t yy_buf_size;
00225 
00226    /* Number of characters read into yy_ch_buf, not including EOB
00227     * characters.
00228     */
00229    int yy_n_chars;
00230 
00231    /* Whether we "own" the buffer - i.e., we know we created it,
00232     * and can realloc() it to grow it, and should free() it to
00233     * delete it.
00234     */
00235    int yy_is_our_buffer;
00236 
00237    /* Whether this is an "interactive" input source; if so, and
00238     * if we're using stdio for input, then we want to use getc()
00239     * instead of fread(), to make sure we stop fetching input after
00240     * each newline.
00241     */
00242    int yy_is_interactive;
00243 
00244    /* Whether we're considered to be at the beginning of a line.
00245     * If so, '^' rules will be active on the next match, otherwise
00246     * not.
00247     */
00248    int yy_at_bol;
00249 
00250     int yy_bs_lineno; /**< The line count. */
00251     int yy_bs_column; /**< The column count. */
00252     
00253    /* Whether to try to fill the input buffer when we reach the
00254     * end of it.
00255     */
00256    int yy_fill_buffer;
00257 
00258    int yy_buffer_status;
00259 
00260 #define YY_BUFFER_NEW 0
00261 #define YY_BUFFER_NORMAL 1
00262    /* When an EOF's been seen but there's still some text to process
00263     * then we mark the buffer as YY_EOF_PENDING, to indicate that we
00264     * shouldn't try reading from the input source any more.  We might
00265     * still have a bunch of tokens to match, though, because of
00266     * possible backing-up.
00267     *
00268     * When we actually see the EOF, we change the status to "new"
00269     * (via ael_yyrestart()), so that the user can continue scanning by
00270     * just pointing yyin at a new input file.
00271     */
00272 #define YY_BUFFER_EOF_PENDING 2
00273 
00274    };
00275 #endif /* !YY_STRUCT_YY_BUFFER_STATE */
00276 
00277 /* We provide macros for accessing buffer states in case in the
00278  * future we want to put the buffer states in a more general
00279  * "scanner state".
00280  *
00281  * Returns the top of the stack, or NULL.
00282  */
00283 #define YY_CURRENT_BUFFER ( yyg->yy_buffer_stack \
00284                           ? yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] \
00285                           : NULL)
00286 
00287 /* Same as previous macro, but useful when we know that the buffer stack is not
00288  * NULL or when we need an lvalue. For internal use only.
00289  */
00290 #define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
00291 
00292 void ael_yyrestart (FILE *input_file ,yyscan_t yyscanner );
00293 void ael_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner );
00294 YY_BUFFER_STATE ael_yy_create_buffer (FILE *file,int size ,yyscan_t yyscanner );
00295 void ael_yy_delete_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner );
00296 void ael_yy_flush_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner );
00297 void ael_yypush_buffer_state (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner );
00298 void ael_yypop_buffer_state (yyscan_t yyscanner );
00299 
00300 static void ael_yyensure_buffer_stack (yyscan_t yyscanner );
00301 static void ael_yy_load_buffer_state (yyscan_t yyscanner );
00302 static void ael_yy_init_buffer (YY_BUFFER_STATE b,FILE *file ,yyscan_t yyscanner );
00303 
00304 #define YY_FLUSH_BUFFER ael_yy_flush_buffer(YY_CURRENT_BUFFER ,yyscanner)
00305 
00306 YY_BUFFER_STATE ael_yy_scan_buffer (char *base,yy_size_t size ,yyscan_t yyscanner );
00307 YY_BUFFER_STATE ael_yy_scan_string (yyconst char *yy_str ,yyscan_t yyscanner );
00308 YY_BUFFER_STATE ael_yy_scan_bytes (yyconst char *bytes,int len ,yyscan_t yyscanner );
00309 
00310 void *ael_yyalloc (yy_size_t ,yyscan_t yyscanner );
00311 void *ael_yyrealloc (void *,yy_size_t ,yyscan_t yyscanner );
00312 void ael_yyfree (void * ,yyscan_t yyscanner );
00313 
00314 #define yy_new_buffer ael_yy_create_buffer
00315 
00316 #define yy_set_interactive(is_interactive) \
00317    { \
00318    if ( ! YY_CURRENT_BUFFER ){ \
00319         ael_yyensure_buffer_stack (yyscanner); \
00320       YY_CURRENT_BUFFER_LVALUE =    \
00321             ael_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
00322    } \
00323    YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
00324    }
00325 
00326 #define yy_set_bol(at_bol) \
00327    { \
00328    if ( ! YY_CURRENT_BUFFER ){\
00329         ael_yyensure_buffer_stack (yyscanner); \
00330       YY_CURRENT_BUFFER_LVALUE =    \
00331             ael_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
00332    } \
00333    YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
00334    }
00335 
00336 #define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
00337 
00338 /* Begin user sect3 */
00339 
00340 #define ael_yywrap(n) 1
00341 #define YY_SKIP_YYWRAP
00342 
00343 typedef unsigned char YY_CHAR;
00344 
00345 typedef int yy_state_type;
00346 
00347 #define yytext_ptr yytext_r
00348 
00349 static yy_state_type yy_get_previous_state (yyscan_t yyscanner );
00350 static yy_state_type yy_try_NUL_trans (yy_state_type current_state  ,yyscan_t yyscanner);
00351 static int yy_get_next_buffer (yyscan_t yyscanner );
00352 static void yy_fatal_error (yyconst char msg[] ,yyscan_t yyscanner );
00353 
00354 /* Done after the current pattern has been matched and before the
00355  * corresponding action - sets up yytext.
00356  */
00357 #define YY_DO_BEFORE_ACTION \
00358    yyg->yytext_ptr = yy_bp; \
00359    yyg->yytext_ptr -= yyg->yy_more_len; \
00360    yyleng = (size_t) (yy_cp - yyg->yytext_ptr); \
00361    yyg->yy_hold_char = *yy_cp; \
00362    *yy_cp = '\0'; \
00363    yyg->yy_c_buf_p = yy_cp;
00364 
00365 #define YY_NUM_RULES 76
00366 #define YY_END_OF_BUFFER 77
00367 /* This struct is not used in this scanner,
00368    but its presence is necessary. */
00369 struct yy_trans_info
00370    {
00371    flex_int32_t yy_verify;
00372    flex_int32_t yy_nxt;
00373    };
00374 static yyconst flex_int16_t yy_accept[285] =
00375     {   0,
00376         0,    0,    0,    0,    0,    0,    0,    0,   43,   43,
00377         0,    0,    0,    0,    0,    0,   77,   75,   50,   48,
00378        49,   51,   51,   51,    9,    3,    4,    7,   51,    8,
00379         5,    6,   12,   75,   51,   51,   51,   51,   51,   51,
00380        51,   51,   51,   51,   51,   51,   51,   51,   51,   51,
00381         1,   10,    2,   75,   65,   64,   75,   66,   75,   71,
00382        72,   73,   75,   75,   67,   68,   69,   75,   70,   43,
00383        44,   45,   75,   59,   60,   75,   58,   57,   52,   52,
00384        57,   53,   75,   62,   63,   75,   61,   50,   49,    0,
00385        51,   42,   13,   11,    0,    0,    0,    0,    0,    0,
00386 
00387         0,    0,    0,    0,    0,    0,   22,    0,    0,    0,
00388         0,    0,    0,    0,    0,    0,    0,    0,   65,   64,
00389         0,   66,   65,   64,   66,    0,   71,   72,   73,    0,
00390        71,   72,   73,    0,   67,   68,   69,    0,   70,   67,
00391        68,   69,   70,   43,   44,   45,   46,   45,   47,    0,
00392        59,   60,    0,   58,   59,   60,   58,   56,   55,   54,
00393         0,   62,   63,    0,   61,   62,   63,   61,    0,   13,
00394         0,    0,    0,    0,    0,    0,    0,    0,    0,   33,
00395         0,    0,    0,   51,    0,    0,    0,    0,    0,    0,
00396         0,    0,    0,    0,    0,    0,    0,    0,   35,    0,
00397 
00398         0,    0,   27,    0,    0,    0,   28,   26,    0,    0,
00399         0,   29,    0,    0,    0,    0,    0,    0,    0,    0,
00400         0,    0,   31,   38,    0,    0,    0,    0,    0,    0,
00401         0,    0,    0,   19,   17,    0,    0,    0,    0,    0,
00402        34,    0,    0,    0,    0,    0,    0,   16,    0,   23,
00403         0,    0,    0,   24,    0,   30,   21,    0,    0,   14,
00404         0,   36,    0,   18,    0,    0,   37,    0,   51,    0,
00405        15,   32,    0,    0,   41,   25,   39,    0,   40,   20,
00406         0,    0,   74,    0
00407     } ;
00408 
00409 static yyconst flex_int32_t yy_ec[256] =
00410     {   0,
00411         1,    1,    1,    1,    1,    1,    1,    1,    2,    3,
00412         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00413         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00414         1,    4,    5,    6,    7,    8,    1,    9,    5,   10,
00415        11,   12,    5,   13,    5,    5,   14,    5,    5,    5,
00416         5,    5,    5,    5,    5,    5,    5,   15,   16,    5,
00417        17,   18,    1,   19,    5,    5,    5,    5,    5,    5,
00418         5,    5,    5,    5,    5,    5,    5,    5,    5,    5,
00419         5,    5,    5,   20,    5,    5,    5,    5,    5,    5,
00420        21,   22,   23,    1,    5,    1,   24,   25,   26,   27,
00421 
00422        28,   29,   30,   31,   32,   33,   34,   35,   36,   37,
00423        38,   39,    5,   40,   41,   42,   43,    5,   44,   45,
00424         5,    5,   46,   47,   48,    1,    1,   49,   49,   49,
00425        49,   49,   49,   49,   49,   49,   49,   49,   49,   49,
00426        49,   49,   49,   49,   49,   49,   49,   49,   49,   49,
00427        49,   49,   49,   49,   49,   49,   49,   49,   49,   49,
00428        49,   49,   49,   49,   49,   49,   49,   49,   49,   49,
00429        49,   49,   49,   49,   49,   49,   49,   49,   49,   49,
00430        49,   49,   49,   49,   49,   49,   49,   49,   49,   49,
00431        49,   49,   49,   49,   49,   49,   49,   49,   49,   49,
00432 
00433        49,   49,   49,   49,   49,   49,   49,   49,   49,   49,
00434        49,   49,   49,   49,   49,   49,   49,   49,   49,   49,
00435        49,   49,   49,   49,   49,   49,   49,   49,   49,   49,
00436        49,   49,   49,   49,   49,   49,   49,   49,   49,   49,
00437        49,   49,   49,   49,   49,   49,   49,   49,   49,   49,
00438        49,   49,   49,   49,   49
00439     } ;
00440 
00441 static yyconst flex_int32_t yy_meta[50] =
00442     {   0,
00443         1,    1,    2,    1,    3,    4,    3,    3,    1,    1,
00444         1,    5,    1,    3,    1,    1,    1,    3,    1,    3,
00445         3,    1,    3,    3,    3,    3,    3,    3,    3,    3,
00446         3,    3,    3,    3,    3,    3,    3,    3,    3,    3,
00447         3,    3,    3,    3,    3,    1,    1,    1,    1
00448     } ;
00449 
00450 static yyconst flex_int16_t yy_base[304] =
00451     {   0,
00452         0,    0,   40,   43,   82,  121,  160,  199,   55,   56,
00453        60,   74,  247,  296,   90,  104,  432, 1023,  429, 1023,
00454       426, 1023,  397,   31, 1023, 1023, 1023, 1023,   43, 1023,
00455      1023,  410, 1023,    0,  401,  382,   36,  389,   34,  378,
00456        38,  380,   80,  368,  372,  385,  381,   66,  357,  369,
00457      1023, 1023, 1023,  138, 1023, 1023,  143, 1023,  336, 1023,
00458      1023, 1023,  375,  414, 1023, 1023, 1023,  453, 1023,  396,
00459      1023,  104,  177, 1023, 1023,  182, 1023, 1023, 1023,   78,
00460         0, 1023,  231, 1023, 1023,  262, 1023,  393,  390,  356,
00461      1023, 1023,    0, 1023,  348,  360,   92,  350,  354,  337,
00462 
00463       333,  333,  333,  334,  329,  333,  344,  326,  335,  320,
00464       327,  322,  299,  303,   93,  302,  301,  280, 1023, 1023,
00465       314, 1023,  328,  344,  358,  492, 1023, 1023, 1023,  531,
00466       570,  609,  648,  687, 1023, 1023, 1023,  726, 1023,  765,
00467       804,  843,  882,  329, 1023,  143, 1023,  144, 1023,  392,
00468      1023, 1023,  397, 1023,  431,  436,  470, 1023, 1023, 1023,
00469       475, 1023, 1023,  484, 1023,  514,  523,  553,  305,    0,
00470       288,  305,  299,  297,  280,  297,  292,  287,  289,    0,
00471       291,  276,  250,  257,  250,  252,  247,  258,  241,  238,
00472       251,  248,  232,  232,  236,  235,  228,  233,    0,  234,
00473 
00474       113,  218,    0,  217,  209,  220,    0,    0,  207,  200,
00475       196,    0,  203,  199,  208,  197,  189,  193,  206,  203,
00476       186,  203,    0,    0,  181,  187,  184,  192,  190,  181,
00477       187,  186,  186,    0,    0,  171,  171,  160,  164,  166,
00478         0,  169,  169,  152,  147,  143,  149,    0,  138,    0,
00479       139,  149,  138,    0,  140,    0,  135,  134,  109,    0,
00480       112,    0,  111,    0,  105,   80,    0,   82,   61,   76,
00481         0,    0,   46,   30,    0,    0,    0,  170,    0,    0,
00482         0,   50, 1023, 1023,  930,  935,  940,  945,  950,  955,
00483       960,  965,  970,  975,  980,  985,  989,  994,  999, 1004,
00484 
00485      1009, 1012, 1017
00486     } ;
00487 
00488 static yyconst flex_int16_t yy_def[304] =
00489     {   0,
00490       284,    1,  285,  285,  286,  286,  287,  287,  288,  288,
00491       289,  289,  290,  290,  291,  291,  284,  284,  284,  284,
00492       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00493       284,  284,  284,  292,  284,  284,  284,  284,  284,  284,
00494       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00495       284,  284,  284,  293,  284,  284,  293,  284,  294,  284,
00496       284,  284,  294,  295,  284,  284,  284,  295,  284,  296,
00497       284,  297,  298,  284,  284,  298,  284,  284,  284,  284,
00498       299,  284,  300,  284,  284,  300,  284,  284,  284,  284,
00499       284,  284,  301,  284,  284,  284,  284,  284,  284,  284,
00500 
00501       284,  284,  284,  284,  284,  284,  302,  284,  284,  284,
00502       284,  284,  284,  284,  284,  284,  284,  293,  284,  284,
00503       293,  284,  293,  293,  293,  294,  284,  284,  284,  294,
00504       294,  294,  294,  295,  284,  284,  284,  295,  284,  295,
00505       295,  295,  295,  296,  284,  297,  284,  297,  284,  298,
00506       284,  284,  298,  284,  298,  298,  298,  284,  284,  284,
00507       300,  284,  284,  300,  284,  300,  300,  300,  284,  301,
00508       284,  284,  284,  284,  284,  284,  284,  284,  284,  302,
00509       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00510       284,  284,  284,  284,  284,  284,  284,  284,  302,  284,
00511 
00512       284,  284,  302,  284,  284,  284,  302,  302,  284,  284,
00513       284,  302,  284,  284,  284,  284,  284,  284,  284,  284,
00514       284,  284,  302,  302,  284,  284,  284,  284,  284,  284,
00515       284,  284,  284,  302,  302,  284,  284,  284,  284,  284,
00516       302,  284,  284,  284,  284,  284,  284,  302,  284,  302,
00517       284,  284,  284,  302,  284,  302,  302,  284,  284,  302,
00518       284,  302,  284,  302,  284,  284,  302,  284,  284,  284,
00519       302,  302,  284,  284,  302,  302,  302,  284,  302,  302,
00520       303,  303,  284,    0,  284,  284,  284,  284,  284,  284,
00521       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00522 
00523       284,  284,  284
00524     } ;
00525 
00526 static yyconst flex_int16_t yy_nxt[1073] =
00527     {   0,
00528        18,   19,   20,   21,   22,   22,   23,   24,   25,   26,
00529        27,   22,   28,   29,   30,   31,   32,   22,   33,   22,
00530        22,   34,   22,   35,   36,   37,   38,   39,   40,   41,
00531        42,   43,   44,   22,   45,   46,   22,   22,   47,   48,
00532        49,   22,   22,   50,   22,   51,   52,   53,   22,   55,
00533        56,   91,   55,   56,   92,  283,   93,   71,   71,   97,
00534        55,   57,   58,   55,   57,   58,   72,   72,  100,   74,
00535        75,  280,  104,   98,  101,  105,   91,  278,  102,  278,
00536        74,   76,   75,   74,   75,   55,  279,   58,   55,  114,
00537        58,   60,   61,  115,   74,   76,   75,   62,  158,   84,
00538 
00539        85,  277,   60,   63,   61,   74,  147,   77,  107,  108,
00540        84,   86,   87,   84,   85,  148,  109,  149,  276,   74,
00541       275,   77,  192,  159,   84,   86,   87,   60,  274,   61,
00542        60,   61,  173,  174,  193,   84,   62,   85,  273,  272,
00543       225,   60,   63,   61,  226,  147,  147,  119,  120,   84,
00544       271,   85,  123,  124,  284,  148,  284,  284,  119,  121,
00545       122,  270,  269,  123,  121,  125,   60,  268,   61,   65,
00546        66,  278,   67,  278,  267,  281,  266,  265,  264,  263,
00547        65,   68,   69,  119,  262,  122,  151,  152,  123,  261,
00548       125,  155,  156,  260,  259,  258,  257,  151,  153,  152,
00549 
00550       256,  255,  155,  153,  156,   65,  254,   69,   65,   66,
00551       253,   67,  252,  251,  250,  249,  248,  247,  246,   65,
00552        68,   69,  151,  245,  154,  244,  243,  155,  242,  157,
00553       241,  240,  239,  238,  237,  236,  235,  234,  233,  232,
00554       162,  163,  231,  230,   65,  229,   69,   78,   78,   78,
00555        78,  162,  164,  165,   80,   78,   78,   78,  228,   78,
00556       227,   78,   78,   78,  224,   78,  223,  222,   81,  221,
00557       220,  166,  167,  219,  218,  217,  162,  216,  163,  215,
00558       214,  213,  166,  164,  168,  212,  211,  210,  209,  119,
00559       120,  208,   78,   78,   78,   82,   78,   78,   78,   78,
00560 
00561       119,  121,  122,   80,   78,   78,   78,  166,   78,  167,
00562        78,   78,   78,  207,   78,  206,  205,   81,  204,  203,
00563       202,  201,  200,  123,  124,  119,  199,  122,  198,  197,
00564       196,  145,  195,  194,  123,  121,  125,  119,  120,  191,
00565       190,   78,   78,   78,   82,  127,  128,  189,  119,  121,
00566       122,  129,  188,  119,  120,  187,  127,  130,  128,  123,
00567       186,  125,  185,  184,  119,  121,  122,  119,  120,  183,
00568       182,  181,  180,  119,  179,  122,  178,  177,  119,  121,
00569       122,  127,  176,  128,  131,  132,  175,  172,  171,  119,
00570       133,  122,  169,   89,   88,  131,  130,  132,  145,  117,
00571 
00572       116,  151,  152,  119,  113,  122,  155,  156,  112,  111,
00573       110,  106,  151,  153,  152,  103,   99,  155,  153,  156,
00574       131,   96,  132,  135,  136,   95,  137,   94,   90,   89,
00575        88,  284,  284,  284,  135,  138,  139,  151,  284,  154,
00576       151,  152,  155,  284,  157,  151,  152,  284,  284,  284,
00577       284,  151,  153,  152,  284,  284,  151,  153,  152,  135,
00578       284,  139,  140,  141,  284,  142,  284,  284,  284,  284,
00579       284,  284,  284,  140,  138,  143,  151,  284,  154,  151,
00580       152,  151,  284,  154,  162,  163,  284,  284,  284,  284,
00581       151,  153,  152,  166,  167,  162,  164,  165,  140,  284,
00582 
00583       143,  127,  128,  284,  166,  164,  168,  129,  284,  284,
00584       284,  284,  127,  130,  128,  151,  284,  154,  284,  284,
00585       162,  284,  163,  162,  163,  284,  284,  284,  284,  166,
00586       284,  167,  162,  163,  162,  164,  165,  127,  284,  128,
00587       131,  132,  284,  162,  164,  165,  133,  284,  284,  284,
00588       284,  131,  130,  132,  284,  284,  284,  284,  284,  162,
00589       284,  163,  162,  163,  284,  284,  284,  284,  162,  284,
00590       163,  284,  284,  162,  164,  165,  131,  284,  132,  127,
00591       128,  284,  284,  284,  284,  129,  284,  284,  284,  284,
00592       127,  130,  128,  284,  284,  284,  284,  284,  162,  284,
00593 
00594       163,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00595       284,  284,  284,  284,  284,  127,  284,  128,  127,  128,
00596       284,  284,  284,  284,  129,  284,  284,  284,  284,  127,
00597       130,  128,  284,  284,  284,  284,  284,  284,  284,  284,
00598       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00599       284,  284,  284,  284,  127,  284,  128,  127,  128,  284,
00600       284,  284,  284,  129,  284,  284,  284,  284,  127,  130,
00601       128,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00602       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00603       284,  284,  284,  127,  284,  128,  135,  136,  284,  137,
00604 
00605       284,  284,  284,  284,  284,  284,  284,  135,  138,  139,
00606       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00607       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00608       284,  284,  135,  284,  139,  140,  141,  284,  142,  284,
00609       284,  284,  284,  284,  284,  284,  140,  138,  143,  284,
00610       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00611       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00612       284,  140,  284,  143,  135,  136,  284,  137,  284,  284,
00613       284,  284,  284,  284,  284,  135,  138,  139,  284,  284,
00614       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00615 
00616       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00617       135,  284,  139,  135,  136,  284,  137,  284,  284,  284,
00618       284,  284,  284,  284,  135,  138,  139,  284,  284,  284,
00619       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00620       284,  284,  284,  284,  284,  284,  284,  284,  284,  135,
00621       284,  139,  135,  136,  284,  137,  284,  284,  284,  284,
00622       284,  284,  284,  135,  138,  139,  284,  284,  284,  284,
00623       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00624       284,  284,  284,  284,  284,  284,  284,  284,  135,  284,
00625       139,  135,  136,  284,  137,  284,  284,  284,  284,  284,
00626 
00627       284,  284,  135,  138,  139,  284,  284,  284,  284,  284,
00628       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00629       284,  284,  284,  284,  284,  284,  284,  135,  284,  139,
00630        54,   54,   54,   54,   54,   59,   59,   59,   59,   59,
00631        64,   64,   64,   64,   64,   70,   70,   70,   70,   70,
00632        73,   73,   73,   73,   73,   79,   79,   79,   79,   79,
00633        83,   83,   83,   83,   83,   91,  284,   91,   91,   91,
00634       118,  118,  118,  118,  118,  126,  126,  126,  126,  126,
00635       134,  134,  134,  134,  134,  144,  144,  144,  144,  146,
00636       146,  146,  146,  146,  150,  150,  150,  150,  150,  160,
00637 
00638       284,  160,  160,  160,  161,  161,  161,  161,  161,  170,
00639       284,  170,  170,  170,   91,   91,   91,  282,  282,  282,
00640       284,  282,   17,  284,  284,  284,  284,  284,  284,  284,
00641       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00642       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00643       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00644       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00645       284,  284
00646     } ;
00647 
00648 static yyconst flex_int16_t yy_chk[1073] =
00649     {   0,
00650         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00651         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00652         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00653         1,    1,    1,    1,    1,    1,    1,    1,    1,    1,
00654         1,    1,    1,    1,    1,    1,    1,    1,    1,    3,
00655         3,   24,    4,    4,   29,  282,   29,    9,   10,   37,
00656         3,    3,    3,    4,    4,    4,    9,   10,   39,   11,
00657        11,  274,   41,   37,   39,   41,   24,  270,   39,  270,
00658        11,   11,   11,   12,   12,    3,  273,    3,    4,   48,
00659         4,    5,    5,   48,   12,   12,   12,    5,   80,   15,
00660 
00661        15,  269,    5,    5,    5,   11,   72,   11,   43,   43,
00662        15,   15,   15,   16,   16,   72,   43,   72,  268,   12,
00663       266,   12,  115,   80,   16,   16,   16,    5,  265,    5,
00664         6,    6,   97,   97,  115,   15,    6,   15,  263,  261,
00665       201,    6,    6,    6,  201,  146,  148,   54,   54,   16,
00666       259,   16,   57,   57,  146,  148,  146,  148,   54,   54,
00667        54,  258,  257,   57,   57,   57,    6,  255,    6,    7,
00668         7,  278,    7,  278,  253,  278,  252,  251,  249,  247,
00669         7,    7,    7,   54,  246,   54,   73,   73,   57,  245,
00670        57,   76,   76,  244,  243,  242,  240,   73,   73,   73,
00671 
00672       239,  238,   76,   76,   76,    7,  237,    7,    8,    8,
00673       236,    8,  233,  232,  231,  230,  229,  228,  227,    8,
00674         8,    8,   73,  226,   73,  225,  222,   76,  221,   76,
00675       220,  219,  218,  217,  216,  215,  214,  213,  211,  210,
00676        83,   83,  209,  206,    8,  205,    8,   13,   13,   13,
00677        13,   83,   83,   83,   13,   13,   13,   13,  204,   13,
00678       202,   13,   13,   13,  200,   13,  198,  197,   13,  196,
00679       195,   86,   86,  194,  193,  192,   83,  191,   83,  190,
00680       189,  188,   86,   86,   86,  187,  186,  185,  184,  118,
00681       118,  183,   13,   13,   13,   13,   14,   14,   14,   14,
00682 
00683       118,  118,  118,   14,   14,   14,   14,   86,   14,   86,
00684        14,   14,   14,  182,   14,  181,  179,   14,  178,  177,
00685       176,  175,  174,  121,  121,  118,  173,  118,  172,  171,
00686       169,  144,  117,  116,  121,  121,  121,  123,  123,  114,
00687       113,   14,   14,   14,   14,   59,   59,  112,  123,  123,
00688       123,   59,  111,  124,  124,  110,   59,   59,   59,  121,
00689       109,  121,  108,  107,  124,  124,  124,  125,  125,  106,
00690       105,  104,  103,  123,  102,  123,  101,  100,  125,  125,
00691       125,   59,   99,   59,   63,   63,   98,   96,   95,  124,
00692        63,  124,   90,   89,   88,   63,   63,   63,   70,   50,
00693 
00694        49,  150,  150,  125,   47,  125,  153,  153,   46,   45,
00695        44,   42,  150,  150,  150,   40,   38,  153,  153,  153,
00696        63,   36,   63,   64,   64,   35,   64,   32,   23,   21,
00697        19,   17,    0,    0,   64,   64,   64,  150,    0,  150,
00698       155,  155,  153,    0,  153,  156,  156,    0,    0,    0,
00699         0,  155,  155,  155,    0,    0,  156,  156,  156,   64,
00700         0,   64,   68,   68,    0,   68,    0,    0,    0,    0,
00701         0,    0,    0,   68,   68,   68,  155,    0,  155,  157,
00702       157,  156,    0,  156,  161,  161,    0,    0,    0,    0,
00703       157,  157,  157,  164,  164,  161,  161,  161,   68,    0,
00704 
00705        68,  126,  126,    0,  164,  164,  164,  126,    0,    0,
00706         0,    0,  126,  126,  126,  157,    0,  157,    0,    0,
00707       161,    0,  161,  166,  166,    0,    0,    0,    0,  164,
00708         0,  164,  167,  167,  166,  166,  166,  126,    0,  126,
00709       130,  130,    0,  167,  167,  167,  130,    0,    0,    0,
00710         0,  130,  130,  130,    0,    0,    0,    0,    0,  166,
00711         0,  166,  168,  168,    0,    0,    0,    0,  167,    0,
00712       167,    0,    0,  168,  168,  168,  130,    0,  130,  131,
00713       131,    0,    0,    0,    0,  131,    0,    0,    0,    0,
00714       131,  131,  131,    0,    0,    0,    0,    0,  168,    0,
00715 
00716       168,    0,    0,    0,    0,    0,    0,    0,    0,    0,
00717         0,    0,    0,    0,    0,  131,    0,  131,  132,  132,
00718         0,    0,    0,    0,  132,    0,    0,    0,    0,  132,
00719       132,  132,    0,    0,    0,    0,    0,    0,    0,    0,
00720         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
00721         0,    0,    0,    0,  132,    0,  132,  133,  133,    0,
00722         0,    0,    0,  133,    0,    0,    0,    0,  133,  133,
00723       133,    0,    0,    0,    0,    0,    0,    0,    0,    0,
00724         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
00725         0,    0,    0,  133,    0,  133,  134,  134,    0,  134,
00726 
00727         0,    0,    0,    0,    0,    0,    0,  134,  134,  134,
00728         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
00729         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
00730         0,    0,  134,    0,  134,  138,  138,    0,  138,    0,
00731         0,    0,    0,    0,    0,    0,  138,  138,  138,    0,
00732         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
00733         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
00734         0,  138,    0,  138,  140,  140,    0,  140,    0,    0,
00735         0,    0,    0,    0,    0,  140,  140,  140,    0,    0,
00736         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
00737 
00738         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
00739       140,    0,  140,  141,  141,    0,  141,    0,    0,    0,
00740         0,    0,    0,    0,  141,  141,  141,    0,    0,    0,
00741         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
00742         0,    0,    0,    0,    0,    0,    0,    0,    0,  141,
00743         0,  141,  142,  142,    0,  142,    0,    0,    0,    0,
00744         0,    0,    0,  142,  142,  142,    0,    0,    0,    0,
00745         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
00746         0,    0,    0,    0,    0,    0,    0,    0,  142,    0,
00747       142,  143,  143,    0,  143,    0,    0,    0,    0,    0,
00748 
00749         0,    0,  143,  143,  143,    0,    0,    0,    0,    0,
00750         0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
00751         0,    0,    0,    0,    0,    0,    0,  143,    0,  143,
00752       285,  285,  285,  285,  285,  286,  286,  286,  286,  286,
00753       287,  287,  287,  287,  287,  288,  288,  288,  288,  288,
00754       289,  289,  289,  289,  289,  290,  290,  290,  290,  290,
00755       291,  291,  291,  291,  291,  292,    0,  292,  292,  292,
00756       293,  293,  293,  293,  293,  294,  294,  294,  294,  294,
00757       295,  295,  295,  295,  295,  296,  296,  296,  296,  297,
00758       297,  297,  297,  297,  298,  298,  298,  298,  298,  299,
00759 
00760         0,  299,  299,  299,  300,  300,  300,  300,  300,  301,
00761         0,  301,  301,  301,  302,  302,  302,  303,  303,  303,
00762         0,  303,  284,  284,  284,  284,  284,  284,  284,  284,
00763       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00764       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00765       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00766       284,  284,  284,  284,  284,  284,  284,  284,  284,  284,
00767       284,  284
00768     } ;
00769 
00770 /* The intent behind this definition is that it'll catch
00771  * any uses of REJECT which flex missed.
00772  */
00773 #define REJECT reject_used_but_not_detected
00774 #define yymore() (yyg->yy_more_flag = 1)
00775 #define YY_MORE_ADJ yyg->yy_more_len
00776 #define YY_RESTORE_YY_MORE_OFFSET
00777 #line 1 "ael.flex"
00778 /*
00779  * Asterisk -- An open source telephony toolkit.
00780  *
00781  * Copyright (C) 2006, Digium, Inc.
00782  *
00783  * Steve Murphy <murf@parsetree.com>
00784  *
00785  * See http://www.asterisk.org for more information about
00786  * the Asterisk project. Please do not directly contact
00787  * any of the maintainers of this project for assistance;
00788  * the project provides a web site, mailing lists and IRC
00789  * channels for your use.
00790  *
00791  * This program is free software, distributed under the terms of
00792  * the GNU General Public License Version 2. See the LICENSE file
00793  * at the top of the source tree.
00794  */
00795 /*! \file
00796  *
00797  * \brief Flex scanner description of tokens used in AEL2 .
00798  *
00799  */
00800 /*
00801  * Start with flex options:
00802  *
00803  * %x describes the contexts we have: paren, semic and argg, plus INITIAL
00804  */
00805 
00806 /* prefix used for various globally-visible functions and variables.
00807  * This renames also ael_yywrap, but since we do not use it, we just
00808  * add option noyywrap to remove it.
00809  */
00810 /* I specify this option to suppress flex generating code with ECHO
00811   in it. This generates compiler warnings in some systems; We've
00812   seen the fwrite generate Unused variable warnings with 4.1.2 gcc.
00813   Some systems have tweaked flex ECHO macro to keep the compiler
00814   happy.  To keep the warning message from getting output, I added
00815   a default rule at the end of the patterns section */
00816 /* ael_yyfree normally just frees its arg. It can be null sometimes,
00817    which some systems will complain about, so, we'll define our own version */
00818 /* batch gives a bit more performance if we are using it in
00819  * a non-interactive mode. We probably don't care much.
00820  */
00821 /* outfile is the filename to be used instead of lex.yy.c */
00822 /*
00823  * These are not supported in flex 2.5.4, but we need them
00824  * at the moment:
00825  * reentrant produces a thread-safe parser. Not 100% sure that
00826  * we require it, though.
00827  * bison-bridge passes an additional yylval argument to ael_yylex().
00828  * bison-locations is probably not needed.
00829  */
00830 #line 71 "ael.flex"
00831 #include "asterisk.h"
00832 ASTERISK_FILE_VERSION(__FILE__, "$Revision: 423978 $")
00833 
00834 #include <sys/types.h>
00835 #include <sys/stat.h>
00836 #include <unistd.h>
00837 #include <glob.h>
00838 
00839 #if !defined(GLOB_ABORTED)
00840 #define GLOB_ABORTED GLOB_ABEND
00841 #endif
00842 
00843 #include "asterisk/logger.h"
00844 #include "asterisk/utils.h"
00845 #include "asterisk/lock.h"
00846 #include "asterisk/hashtab.h"
00847 #include "ael/ael.tab.h"
00848 #include "asterisk/ael_structs.h"
00849 
00850 /*
00851  * A stack to keep track of matching brackets ( [ { } ] )
00852  */
00853 static char pbcstack[400]; /* XXX missing size checks */
00854 static int pbcpos = 0;
00855 static void pbcpush(char x);
00856 static int pbcpop(char x);
00857 static int parencount = 0;
00858 
00859 /*
00860  * A similar stack to keep track of matching brackets ( [ { } ] ) in word tokens surrounded by ${ ... }
00861  */
00862 static char pbcstack2[400];   /* XXX missing size checks */
00863 static int pbcpos2 = 0;
00864 static void pbcpush2(char x);
00865 static int pbcpop2(char x);
00866 static int parencount2 = 0;
00867 
00868 /*
00869  * A similar stack to keep track of matching brackets ( [ { } ] ) in word tokens surrounded by $[ ... ]
00870  */
00871 static char pbcstack3[400];   /* XXX missing size checks */
00872 static int pbcpos3 = 0;
00873 static void pbcpush3(char x);
00874 static int pbcpop3(char x);
00875 static int parencount3 = 0;
00876 
00877 
00878 /*
00879  * current line, column and filename, updated as we read the input.
00880  */
00881 static int my_lineno = 1;  /* current line in the source */
00882 static int my_col = 1;     /* current column in the source */
00883 char *my_file = 0;      /* used also in the bison code */
00884 char *prev_word;     /* XXX document it */
00885 
00886 #define MAX_INCLUDE_DEPTH 50
00887 
00888 /*
00889  * flex is not too smart, and generates global functions
00890  * without prototypes so the compiler may complain.
00891  * To avoid that, we declare the prototypes here,
00892  * even though these functions are not used.
00893  */
00894 int ael_yyget_column  (yyscan_t yyscanner);
00895 void ael_yyset_column (int  column_no , yyscan_t yyscanner);
00896 
00897 int ael_yyparse (struct parse_io *);
00898 
00899 /*
00900  * A stack to process include files.
00901  * As we switch into the new file we need to store the previous
00902  * state to restore it later.
00903  */
00904 struct stackelement {
00905    char *fname;
00906    int lineno;
00907    int colno;
00908    glob_t globbuf;        /* the current globbuf */
00909    int globbuf_pos;   /* where we are in the current globbuf */
00910    YY_BUFFER_STATE bufstate;
00911 };
00912 
00913 static struct stackelement  include_stack[MAX_INCLUDE_DEPTH];
00914 static int include_stack_index = 0;
00915 static void setup_filestack(char *fnamebuf, int fnamebuf_siz, glob_t *globbuf, int globpos, yyscan_t xscan, int create);
00916 
00917 /*
00918  * if we use the @n feature of bison, we must supply the start/end
00919  * location of tokens in the structure pointed by yylloc.
00920  * Simple tokens are just assumed to be on the same line, so
00921  * the line number is constant, and the column is incremented
00922  * by the length of the token.
00923  */
00924 #ifdef FLEX_BETA  /* set for 2.5.33 */
00925 
00926 /* compute the total number of lines and columns in the text
00927  * passed as argument.
00928  */
00929 static void pbcwhere(const char *text, int *line, int *col )
00930 {
00931    int loc_line = *line;
00932    int loc_col = *col;
00933    char c;
00934    while ( (c = *text++) ) {
00935       if ( c == '\t' ) {
00936          loc_col += 8 - (loc_col % 8);
00937       } else if ( c == '\n' ) {
00938          loc_line++;
00939          loc_col = 1;
00940       } else
00941          loc_col++;
00942    }
00943    *line = loc_line;
00944    *col = loc_col;
00945 }
00946 
00947 #define  STORE_POS do {                   \
00948       yylloc->first_line = yylloc->last_line = my_lineno;   \
00949       yylloc->first_column=my_col;           \
00950       yylloc->last_column=my_col+yyleng-1;         \
00951       my_col+=yyleng;                  \
00952    } while (0)
00953 
00954 #define  STORE_LOC do {             \
00955       yylloc->first_line = my_lineno;     \
00956       yylloc->first_column=my_col;     \
00957       pbcwhere(yytext, &my_lineno, &my_col); \
00958       yylloc->last_line = my_lineno;      \
00959       yylloc->last_column = my_col - 1;   \
00960    } while (0)
00961 #else
00962 #define  STORE_POS
00963 #define  STORE_LOC
00964 #endif
00965 #line 963 "ael_lex.c"
00966 
00967 #define INITIAL 0
00968 #define paren 1
00969 #define semic 2
00970 #define argg 3
00971 #define comment 4
00972 #define curlystate 5
00973 #define wordstate 6
00974 #define brackstate 7
00975 
00976 #ifndef YY_NO_UNISTD_H
00977 /* Special case for "unistd.h", since it is non-ANSI. We include it way
00978  * down here because we want the user's section 1 to have been scanned first.
00979  * The user has a chance to override it with an option.
00980  */
00981 #include <unistd.h>
00982 #endif
00983 
00984 #ifndef YY_EXTRA_TYPE
00985 #define YY_EXTRA_TYPE void *
00986 #endif
00987 
00988 /* Holds the entire state of the reentrant scanner. */
00989 struct yyguts_t
00990     {
00991 
00992     /* User-defined. Not touched by flex. */
00993     YY_EXTRA_TYPE yyextra_r;
00994 
00995     /* The rest are the same as the globals declared in the non-reentrant scanner. */
00996     FILE *yyin_r, *yyout_r;
00997     size_t yy_buffer_stack_top; /**< index of top of stack. */
00998     size_t yy_buffer_stack_max; /**< capacity of stack. */
00999     YY_BUFFER_STATE * yy_buffer_stack; /**< Stack as an array. */
01000     char yy_hold_char;
01001     int yy_n_chars;
01002     int yyleng_r;
01003     char *yy_c_buf_p;
01004     int yy_init;
01005     int yy_start;
01006     int yy_did_buffer_switch_on_eof;
01007     int yy_start_stack_ptr;
01008     int yy_start_stack_depth;
01009     int *yy_start_stack;
01010     yy_state_type yy_last_accepting_state;
01011     char* yy_last_accepting_cpos;
01012 
01013     int yylineno_r;
01014     int yy_flex_debug_r;
01015 
01016     char *yytext_r;
01017     int yy_more_flag;
01018     int yy_more_len;
01019 
01020     YYSTYPE * yylval_r;
01021 
01022     YYLTYPE * yylloc_r;
01023 
01024     }; /* end struct yyguts_t */
01025 
01026 static int yy_init_globals (yyscan_t yyscanner );
01027 
01028     /* This must go here because YYSTYPE and YYLTYPE are included
01029      * from bison output in section 1.*/
01030     #    define yylval yyg->yylval_r
01031     
01032     #    define yylloc yyg->yylloc_r
01033     
01034 int ael_yylex_init (yyscan_t* scanner);
01035 
01036 int ael_yylex_init_extra (YY_EXTRA_TYPE user_defined,yyscan_t* scanner);
01037 
01038 /* Accessor methods to globals.
01039    These are made visible to non-reentrant scanners for convenience. */
01040 
01041 int ael_yylex_destroy (yyscan_t yyscanner );
01042 
01043 int ael_yyget_debug (yyscan_t yyscanner );
01044 
01045 void ael_yyset_debug (int debug_flag ,yyscan_t yyscanner );
01046 
01047 YY_EXTRA_TYPE ael_yyget_extra (yyscan_t yyscanner );
01048 
01049 void ael_yyset_extra (YY_EXTRA_TYPE user_defined ,yyscan_t yyscanner );
01050 
01051 FILE *ael_yyget_in (yyscan_t yyscanner );
01052 
01053 void ael_yyset_in  (FILE * in_str ,yyscan_t yyscanner );
01054 
01055 FILE *ael_yyget_out (yyscan_t yyscanner );
01056 
01057 void ael_yyset_out  (FILE * out_str ,yyscan_t yyscanner );
01058 
01059 int ael_yyget_leng (yyscan_t yyscanner );
01060 
01061 char *ael_yyget_text (yyscan_t yyscanner );
01062 
01063 int ael_yyget_lineno (yyscan_t yyscanner );
01064 
01065 void ael_yyset_lineno (int line_number ,yyscan_t yyscanner );
01066 
01067 YYSTYPE * ael_yyget_lval (yyscan_t yyscanner );
01068 
01069 void ael_yyset_lval (YYSTYPE * yylval_param ,yyscan_t yyscanner );
01070 
01071        YYLTYPE *ael_yyget_lloc (yyscan_t yyscanner );
01072     
01073         void ael_yyset_lloc (YYLTYPE * yylloc_param ,yyscan_t yyscanner );
01074     
01075 /* Macros after this point can all be overridden by user definitions in
01076  * section 1.
01077  */
01078 
01079 #ifndef YY_SKIP_YYWRAP
01080 #ifdef __cplusplus
01081 extern "C" int ael_yywrap (yyscan_t yyscanner );
01082 #else
01083 extern int ael_yywrap (yyscan_t yyscanner );
01084 #endif
01085 #endif
01086 
01087     static void yyunput (int c,char *buf_ptr  ,yyscan_t yyscanner);
01088     
01089 #ifndef yytext_ptr
01090 static void yy_flex_strncpy (char *,yyconst char *,int ,yyscan_t yyscanner);
01091 #endif
01092 
01093 #ifdef YY_NEED_STRLEN
01094 static int yy_flex_strlen (yyconst char * ,yyscan_t yyscanner);
01095 #endif
01096 
01097 #ifndef YY_NO_INPUT
01098 
01099 #ifdef __cplusplus
01100 static int yyinput (yyscan_t yyscanner );
01101 #else
01102 static int input (yyscan_t yyscanner );
01103 #endif
01104 
01105 #endif
01106 
01107 /* Amount of stuff to slurp up with each read. */
01108 #ifndef YY_READ_BUF_SIZE
01109 #ifdef __ia64__
01110 /* On IA-64, the buffer size is 16k, not 8k */
01111 #define YY_READ_BUF_SIZE 16384
01112 #else
01113 #define YY_READ_BUF_SIZE 8192
01114 #endif /* __ia64__ */
01115 #endif
01116 
01117 /* Copy whatever the last rule matched to the standard output. */
01118 #ifndef ECHO
01119 /* This used to be an fputs(), but since the string might contain NUL's,
01120  * we now use fwrite().
01121  */
01122 #define ECHO do { if (fwrite( yytext, yyleng, 1, yyout )) {} } while (0)
01123 #endif
01124 
01125 /* Gets input and stuffs it into "buf".  number of characters read, or YY_NULL,
01126  * is returned in "result".
01127  */
01128 #ifndef YY_INPUT
01129 #define YY_INPUT(buf,result,max_size) \
01130    if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
01131       { \
01132       int c = '*'; \
01133       size_t n; \
01134       for ( n = 0; n < max_size && \
01135               (c = getc( yyin )) != EOF && c != '\n'; ++n ) \
01136          buf[n] = (char) c; \
01137       if ( c == '\n' ) \
01138          buf[n++] = (char) c; \
01139       if ( c == EOF && ferror( yyin ) ) \
01140          YY_FATAL_ERROR( "input in flex scanner failed" ); \
01141       result = n; \
01142       } \
01143    else \
01144       { \
01145       errno=0; \
01146       while ( (result = fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \
01147          { \
01148          if( errno != EINTR) \
01149             { \
01150             YY_FATAL_ERROR( "input in flex scanner failed" ); \
01151             break; \
01152             } \
01153          errno=0; \
01154          clearerr(yyin); \
01155          } \
01156       }\
01157 \
01158 
01159 #endif
01160 
01161 /* No semi-colon after return; correct usage is to write "yyterminate();" -
01162  * we don't want an extra ';' after the "return" because that will cause
01163  * some compilers to complain about unreachable statements.
01164  */
01165 #ifndef yyterminate
01166 #define yyterminate() return YY_NULL
01167 #endif
01168 
01169 /* Number of entries by which start-condition stack grows. */
01170 #ifndef YY_START_STACK_INCR
01171 #define YY_START_STACK_INCR 25
01172 #endif
01173 
01174 /* Report a fatal error. */
01175 #ifndef YY_FATAL_ERROR
01176 #define YY_FATAL_ERROR(msg) yy_fatal_error( msg , yyscanner)
01177 #endif
01178 
01179 /* end tables serialization structures and prototypes */
01180 
01181 /* Default declaration of generated scanner - a define so the user can
01182  * easily add parameters.
01183  */
01184 #ifndef YY_DECL
01185 #define YY_DECL_IS_OURS 1
01186 
01187 extern int ael_yylex \
01188                (YYSTYPE * yylval_param,YYLTYPE * yylloc_param ,yyscan_t yyscanner);
01189 
01190 #define YY_DECL int ael_yylex \
01191                (YYSTYPE * yylval_param, YYLTYPE * yylloc_param , yyscan_t yyscanner)
01192 #endif /* !YY_DECL */
01193 
01194 /* Code executed at the beginning of each rule, after yytext and yyleng
01195  * have been set up.
01196  */
01197 #ifndef YY_USER_ACTION
01198 #define YY_USER_ACTION
01199 #endif
01200 
01201 /* Code executed at the end of each rule. */
01202 #ifndef YY_BREAK
01203 #define YY_BREAK break;
01204 #endif
01205 
01206 #define YY_RULE_SETUP \
01207    YY_USER_ACTION
01208 
01209 /** The main scanner function which does all the work.
01210  */
01211 YY_DECL
01212 {
01213    register yy_state_type yy_current_state;
01214    register char *yy_cp, *yy_bp;
01215    register int yy_act;
01216     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
01217 
01218 #line 217 "ael.flex"
01219 
01220 
01221 #line 1219 "ael_lex.c"
01222 
01223     yylval = yylval_param;
01224 
01225     yylloc = yylloc_param;
01226 
01227    if ( !yyg->yy_init )
01228       {
01229       yyg->yy_init = 1;
01230 
01231 #ifdef YY_USER_INIT
01232       YY_USER_INIT;
01233 #endif
01234 
01235       if ( ! yyg->yy_start )
01236          yyg->yy_start = 1;   /* first start state */
01237 
01238       if ( ! yyin )
01239          yyin = stdin;
01240 
01241       if ( ! yyout )
01242          yyout = stdout;
01243 
01244       if ( ! YY_CURRENT_BUFFER ) {
01245          ael_yyensure_buffer_stack (yyscanner);
01246          YY_CURRENT_BUFFER_LVALUE =
01247             ael_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner);
01248       }
01249 
01250       ael_yy_load_buffer_state(yyscanner );
01251       }
01252 
01253    while ( 1 )    /* loops until end-of-file is reached */
01254       {
01255       yyg->yy_more_len = 0;
01256       if ( yyg->yy_more_flag )
01257          {
01258          yyg->yy_more_len = yyg->yy_c_buf_p - yyg->yytext_ptr;
01259          yyg->yy_more_flag = 0;
01260          }
01261       yy_cp = yyg->yy_c_buf_p;
01262 
01263       /* Support of yytext. */
01264       *yy_cp = yyg->yy_hold_char;
01265 
01266       /* yy_bp points to the position in yy_ch_buf of the start of
01267        * the current run.
01268        */
01269       yy_bp = yy_cp;
01270 
01271       yy_current_state = yyg->yy_start;
01272 yy_match:
01273       do
01274          {
01275          register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
01276          if ( yy_accept[yy_current_state] )
01277             {
01278             yyg->yy_last_accepting_state = yy_current_state;
01279             yyg->yy_last_accepting_cpos = yy_cp;
01280             }
01281          while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
01282             {
01283             yy_current_state = (int) yy_def[yy_current_state];
01284             if ( yy_current_state >= 285 )
01285                yy_c = yy_meta[(unsigned int) yy_c];
01286             }
01287          yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
01288          ++yy_cp;
01289          }
01290       while ( yy_current_state != 284 );
01291       yy_cp = yyg->yy_last_accepting_cpos;
01292       yy_current_state = yyg->yy_last_accepting_state;
01293 
01294 yy_find_action:
01295       yy_act = yy_accept[yy_current_state];
01296 
01297       YY_DO_BEFORE_ACTION;
01298 
01299 do_action:  /* This label is used only to access EOF actions. */
01300 
01301       switch ( yy_act )
01302    { /* beginning of action switch */
01303          case 0: /* must back up */
01304          /* undo the effects of YY_DO_BEFORE_ACTION */
01305          *yy_cp = yyg->yy_hold_char;
01306          yy_cp = yyg->yy_last_accepting_cpos;
01307          yy_current_state = yyg->yy_last_accepting_state;
01308          goto yy_find_action;
01309 
01310 case 1:
01311 YY_RULE_SETUP
01312 #line 219 "ael.flex"
01313 { STORE_POS; return LC;}
01314    YY_BREAK
01315 case 2:
01316 YY_RULE_SETUP
01317 #line 220 "ael.flex"
01318 { STORE_POS; return RC;}
01319    YY_BREAK
01320 case 3:
01321 YY_RULE_SETUP
01322 #line 221 "ael.flex"
01323 { STORE_POS; return LP;}
01324    YY_BREAK
01325 case 4:
01326 YY_RULE_SETUP
01327 #line 222 "ael.flex"
01328 { STORE_POS; return RP;}
01329    YY_BREAK
01330 case 5:
01331 YY_RULE_SETUP
01332 #line 223 "ael.flex"
01333 { STORE_POS; return SEMI;}
01334    YY_BREAK
01335 case 6:
01336 YY_RULE_SETUP
01337 #line 224 "ael.flex"
01338 { STORE_POS; return EQ;}
01339    YY_BREAK
01340 case 7:
01341 YY_RULE_SETUP
01342 #line 225 "ael.flex"
01343 { STORE_POS; return COMMA;}
01344    YY_BREAK
01345 case 8:
01346 YY_RULE_SETUP
01347 #line 226 "ael.flex"
01348 { STORE_POS; return COLON;}
01349    YY_BREAK
01350 case 9:
01351 YY_RULE_SETUP
01352 #line 227 "ael.flex"
01353 { STORE_POS; return AMPER;}
01354    YY_BREAK
01355 case 10:
01356 YY_RULE_SETUP
01357 #line 228 "ael.flex"
01358 { STORE_POS; return BAR;}
01359    YY_BREAK
01360 case 11:
01361 YY_RULE_SETUP
01362 #line 229 "ael.flex"
01363 { STORE_POS; return EXTENMARK;}
01364    YY_BREAK
01365 case 12:
01366 YY_RULE_SETUP
01367 #line 230 "ael.flex"
01368 { STORE_POS; return AT;}
01369    YY_BREAK
01370 case 13:
01371 YY_RULE_SETUP
01372 #line 231 "ael.flex"
01373 {/*comment*/}
01374    YY_BREAK
01375 case 14:
01376 YY_RULE_SETUP
01377 #line 232 "ael.flex"
01378 { STORE_POS; return KW_CONTEXT;}
01379    YY_BREAK
01380 case 15:
01381 YY_RULE_SETUP
01382 #line 233 "ael.flex"
01383 { STORE_POS; return KW_ABSTRACT;}
01384    YY_BREAK
01385 case 16:
01386 YY_RULE_SETUP
01387 #line 234 "ael.flex"
01388 { STORE_POS; return KW_EXTEND;}
01389    YY_BREAK
01390 case 17:
01391 YY_RULE_SETUP
01392 #line 235 "ael.flex"
01393 { STORE_POS; return KW_MACRO;};
01394    YY_BREAK
01395 case 18:
01396 YY_RULE_SETUP
01397 #line 236 "ael.flex"
01398 { STORE_POS; return KW_GLOBALS;}
01399    YY_BREAK
01400 case 19:
01401 YY_RULE_SETUP
01402 #line 237 "ael.flex"
01403 { STORE_POS; return KW_LOCAL;}
01404    YY_BREAK
01405 case 20:
01406 YY_RULE_SETUP
01407 #line 238 "ael.flex"
01408 { STORE_POS; return KW_IGNOREPAT;}
01409    YY_BREAK
01410 case 21:
01411 YY_RULE_SETUP
01412 #line 239 "ael.flex"
01413 { STORE_POS; return KW_SWITCH;}
01414    YY_BREAK
01415 case 22:
01416 YY_RULE_SETUP
01417 #line 240 "ael.flex"
01418 { STORE_POS; return KW_IF;}
01419    YY_BREAK
01420 case 23:
01421 YY_RULE_SETUP
01422 #line 241 "ael.flex"
01423 { STORE_POS; return KW_IFTIME;}
01424    YY_BREAK
01425 case 24:
01426 YY_RULE_SETUP
01427 #line 242 "ael.flex"
01428 { STORE_POS; return KW_RANDOM;}
01429    YY_BREAK
01430 case 25:
01431 YY_RULE_SETUP
01432 #line 243 "ael.flex"
01433 { STORE_POS; return KW_REGEXTEN;}
01434    YY_BREAK
01435 case 26:
01436 YY_RULE_SETUP
01437 #line 244 "ael.flex"
01438 { STORE_POS; return KW_HINT;}
01439    YY_BREAK
01440 case 27:
01441 YY_RULE_SETUP
01442 #line 245 "ael.flex"
01443 { STORE_POS; return KW_ELSE;}
01444    YY_BREAK
01445 case 28:
01446 YY_RULE_SETUP
01447 #line 246 "ael.flex"
01448 { STORE_POS; return KW_GOTO;}
01449    YY_BREAK
01450 case 29:
01451 YY_RULE_SETUP
01452 #line 247 "ael.flex"
01453 { STORE_POS; return KW_JUMP;}
01454    YY_BREAK
01455 case 30:
01456 YY_RULE_SETUP
01457 #line 248 "ael.flex"
01458 { STORE_POS; return KW_RETURN;}
01459    YY_BREAK
01460 case 31:
01461 YY_RULE_SETUP
01462 #line 249 "ael.flex"
01463 { STORE_POS; return KW_BREAK;}
01464    YY_BREAK
01465 case 32:
01466 YY_RULE_SETUP
01467 #line 250 "ael.flex"
01468 { STORE_POS; return KW_CONTINUE;}
01469    YY_BREAK
01470 case 33:
01471 YY_RULE_SETUP
01472 #line 251 "ael.flex"
01473 { STORE_POS; return KW_FOR;}
01474    YY_BREAK
01475 case 34:
01476 YY_RULE_SETUP
01477 #line 252 "ael.flex"
01478 { STORE_POS; return KW_WHILE;}
01479    YY_BREAK
01480 case 35:
01481 YY_RULE_SETUP
01482 #line 253 "ael.flex"
01483 { STORE_POS; return KW_CASE;}
01484    YY_BREAK
01485 case 36:
01486 YY_RULE_SETUP
01487 #line 254 "ael.flex"
01488 { STORE_POS; return KW_DEFAULT;}
01489    YY_BREAK
01490 case 37:
01491 YY_RULE_SETUP
01492 #line 255 "ael.flex"
01493 { STORE_POS; return KW_PATTERN;}
01494    YY_BREAK
01495 case 38:
01496 YY_RULE_SETUP
01497 #line 256 "ael.flex"
01498 { STORE_POS; return KW_CATCH;}
01499    YY_BREAK
01500 case 39:
01501 YY_RULE_SETUP
01502 #line 257 "ael.flex"
01503 { STORE_POS; return KW_SWITCHES;}
01504    YY_BREAK
01505 case 40:
01506 YY_RULE_SETUP
01507 #line 258 "ael.flex"
01508 { STORE_POS; return KW_ESWITCHES;}
01509    YY_BREAK
01510 case 41:
01511 YY_RULE_SETUP
01512 #line 259 "ael.flex"
01513 { STORE_POS; return KW_INCLUDES;}
01514    YY_BREAK
01515 case 42:
01516 YY_RULE_SETUP
01517 #line 260 "ael.flex"
01518 { BEGIN(comment); my_col += 2; }
01519    YY_BREAK
01520 case 43:
01521 YY_RULE_SETUP
01522 #line 262 "ael.flex"
01523 { my_col += yyleng; }
01524    YY_BREAK
01525 case 44:
01526 /* rule 44 can match eol */
01527 YY_RULE_SETUP
01528 #line 263 "ael.flex"
01529 { ++my_lineno; my_col=1;}
01530    YY_BREAK
01531 case 45:
01532 YY_RULE_SETUP
01533 #line 264 "ael.flex"
01534 { my_col += yyleng; }
01535    YY_BREAK
01536 case 46:
01537 /* rule 46 can match eol */
01538 YY_RULE_SETUP
01539 #line 265 "ael.flex"
01540 { ++my_lineno; my_col=1;}
01541    YY_BREAK
01542 case 47:
01543 YY_RULE_SETUP
01544 #line 266 "ael.flex"
01545 { my_col += 2; BEGIN(INITIAL); } /* the nice thing about comments is that you know exactly what ends them */
01546    YY_BREAK
01547 case 48:
01548 /* rule 48 can match eol */
01549 YY_RULE_SETUP
01550 #line 268 "ael.flex"
01551 { my_lineno++; my_col = 1; }
01552    YY_BREAK
01553 case 49:
01554 YY_RULE_SETUP
01555 #line 269 "ael.flex"
01556 { my_col += yyleng; }
01557    YY_BREAK
01558 case 50:
01559 YY_RULE_SETUP
01560 #line 270 "ael.flex"
01561 { my_col += (yyleng*8)-(my_col%8); }
01562    YY_BREAK
01563 case 51:
01564 YY_RULE_SETUP
01565 #line 272 "ael.flex"
01566 { 
01567       /* boy did I open a can of worms when I changed the lexical token "word". 
01568        all the above keywords can be used as a beginning to a "word".-
01569        before, a "word" would match a longer sequence than the above  
01570         keywords, and all would be well. But now "word" is a single char      
01571         and feeds into a statemachine sort of sequence from there on. So...
01572        I added the {KEYWORD}? to the beginning of the word match sequence */
01573 
01574       if (!strcmp(yytext,"${")) {
01575             parencount2 = 0;
01576          pbcpos2 = 0;
01577          pbcpush2('{'); /* push '{' so the last pcbpop (parencount2 = -1) will succeed */
01578          BEGIN(curlystate);
01579          yymore();
01580       } else if (!strcmp(yytext,"$[")) {
01581             parencount3 = 0;
01582          pbcpos3 = 0;
01583          pbcpush3('['); /* push '[' so the last pcbpop (parencount3 = -1) will succeed */
01584          BEGIN(brackstate);
01585          yymore();
01586       } else {
01587           BEGIN(wordstate);
01588          yymore();
01589       }
01590    }
01591    YY_BREAK
01592 case 52:
01593 YY_RULE_SETUP
01594 #line 298 "ael.flex"
01595 { yymore(); /* Keep going */ }
01596    YY_BREAK
01597 case 53:
01598 YY_RULE_SETUP
01599 #line 299 "ael.flex"
01600 { yymore(); /* Keep going */ }
01601    YY_BREAK
01602 case 54:
01603 YY_RULE_SETUP
01604 #line 300 "ael.flex"
01605 { yymore(); /* Keep Going */ }
01606    YY_BREAK
01607 case 55:
01608 YY_RULE_SETUP
01609 #line 301 "ael.flex"
01610 { /* the beginning of a ${} construct. prepare and pop into curlystate */
01611          parencount2 = 0;
01612       pbcpos2 = 0;
01613       pbcpush2('{'); /* push '{' so the last pcbpop (parencount2 = -1) will succeed */
01614       BEGIN(curlystate);
01615       yymore();
01616    }
01617    YY_BREAK
01618 case 56:
01619 YY_RULE_SETUP
01620 #line 308 "ael.flex"
01621 { /* the beginning of a $[] construct. prepare and pop into brackstate */
01622          parencount3 = 0;
01623       pbcpos3 = 0;
01624       pbcpush3('['); /* push '[' so the last pcbpop (parencount3 = -1) will succeed */
01625       BEGIN(brackstate);
01626       yymore();
01627    }
01628    YY_BREAK
01629 case 57:
01630 /* rule 57 can match eol */
01631 YY_RULE_SETUP
01632 #line 315 "ael.flex"
01633 {
01634       /* a non-word constituent char, like a space, tab, curly, paren, etc */
01635       char c = yytext[yyleng-1];
01636       STORE_POS;
01637       yylval->str = malloc(yyleng);
01638       strncpy(yylval->str, yytext, yyleng);
01639       yylval->str[yyleng-1] = 0;
01640       unput(c);  /* put this ending char back in the stream */
01641       BEGIN(0);
01642       return word;
01643    }
01644    YY_BREAK
01645 case 58:
01646 /* rule 58 can match eol */
01647 YY_RULE_SETUP
01648 #line 328 "ael.flex"
01649 {
01650       if ( pbcpop2('}') ) {   /* error */
01651          STORE_LOC;
01652          ast_log(LOG_ERROR,"File=%s, line=%d, column=%d: Mismatched ')' in expression: %s !\n", my_file, my_lineno, my_col, yytext);
01653          BEGIN(0);
01654          yylval->str = malloc(yyleng+1);
01655          strncpy(yylval->str, yytext, yyleng);
01656          yylval->str[yyleng] = 0;
01657          return word;
01658       }
01659       parencount2--;
01660       if ( parencount2 >= 0) {
01661          yymore();
01662       } else {
01663          BEGIN(wordstate); /* Finished with the current ${} construct. Return to word gathering state */
01664          yymore();
01665       }
01666    }
01667    YY_BREAK
01668 case 59:
01669 /* rule 59 can match eol */
01670 YY_RULE_SETUP
01671 #line 347 "ael.flex"
01672 { 
01673       char c = yytext[yyleng-1];
01674       if (c == '{')
01675          parencount2++;
01676       pbcpush2(c);
01677       yymore();
01678    }
01679    YY_BREAK
01680 case 60:
01681 /* rule 60 can match eol */
01682 YY_RULE_SETUP
01683 #line 355 "ael.flex"
01684 { 
01685       char c = yytext[yyleng-1];
01686       if ( pbcpop2(c))  { /* error */
01687          STORE_LOC;
01688          ast_log(LOG_ERROR,"File=%s, line=%d, column=%d: Mismatched '%c' in expression!\n",
01689             my_file, my_lineno, my_col, c);
01690          BEGIN(0);
01691          yylval->str = malloc(yyleng+1);
01692          strncpy(yylval->str, yytext, yyleng);
01693          yylval->str[yyleng] = 0;
01694          return word;
01695       }
01696       yymore();
01697    }
01698    YY_BREAK
01699 case 61:
01700 /* rule 61 can match eol */
01701 YY_RULE_SETUP
01702 #line 371 "ael.flex"
01703 {
01704       if ( pbcpop3(']') ) {   /* error */
01705          STORE_LOC;
01706          ast_log(LOG_ERROR,"File=%s, line=%d, column=%d: Mismatched ')' in expression: %s !\n", my_file, my_lineno, my_col, yytext);
01707          BEGIN(0);
01708          yylval->str = malloc(yyleng+1);
01709          strncpy(yylval->str, yytext, yyleng);
01710          yylval->str[yyleng] = 0;
01711          return word;
01712       }
01713       parencount3--;
01714       if ( parencount3 >= 0) {
01715          yymore();
01716       } else {
01717          BEGIN(wordstate); /* Finished with the current ${} construct. Return to word gathering state */
01718          yymore();
01719       }
01720    }
01721    YY_BREAK
01722 case 62:
01723 /* rule 62 can match eol */
01724 YY_RULE_SETUP
01725 #line 390 "ael.flex"
01726 { 
01727       char c = yytext[yyleng-1];
01728       if (c == '[')
01729          parencount3++;
01730       pbcpush3(c);
01731       yymore();
01732    }
01733    YY_BREAK
01734 case 63:
01735 /* rule 63 can match eol */
01736 YY_RULE_SETUP
01737 #line 398 "ael.flex"
01738 { 
01739       char c = yytext[yyleng-1];
01740       if ( pbcpop3(c))  { /* error */
01741          STORE_LOC;
01742          ast_log(LOG_ERROR,"File=%s, line=%d, column=%d: Mismatched '%c' in expression!\n",
01743             my_file, my_lineno, my_col, c);
01744          BEGIN(0);
01745          yylval->str = malloc(yyleng+1);
01746          strncpy(yylval->str, yytext, yyleng);
01747          yylval->str[yyleng] = 0;
01748          return word;
01749       }
01750       yymore();
01751    }
01752    YY_BREAK
01753 /*
01754     * context used for arguments of if_head, random_head, switch_head,
01755     * for (last statement), while (XXX why not iftime_head ?).
01756     * End with the matching parentheses.
01757     * A comma at the top level is valid here, unlike in argg where it
01758     * is an argument separator so it must be returned as a token.
01759     */
01760 case 64:
01761 /* rule 64 can match eol */
01762 YY_RULE_SETUP
01763 #line 421 "ael.flex"
01764 {
01765       if ( pbcpop(')') ) { /* error */
01766          STORE_LOC;
01767          ast_log(LOG_ERROR,"File=%s, line=%d, column=%d: Mismatched ')' in expression: %s !\n", my_file, my_lineno, my_col, yytext);
01768          BEGIN(0);
01769          yylval->str = malloc(yyleng+1);
01770          strncpy(yylval->str, yytext, yyleng);
01771          yylval->str[yyleng] = 0;
01772          prev_word = 0;
01773          return word;
01774       }
01775       parencount--;
01776       if ( parencount >= 0) {
01777          yymore();
01778       } else {
01779          STORE_LOC;
01780          yylval->str = malloc(yyleng);
01781          strncpy(yylval->str, yytext, yyleng);
01782          yylval->str[yyleng-1] = 0;
01783          unput(')');
01784          BEGIN(0);
01785          return word;
01786       }
01787    }
01788    YY_BREAK
01789 case 65:
01790 /* rule 65 can match eol */
01791 YY_RULE_SETUP
01792 #line 446 "ael.flex"
01793 {
01794       char c = yytext[yyleng-1];
01795       if (c == '(')
01796          parencount++;
01797       pbcpush(c);
01798       yymore();
01799    }
01800    YY_BREAK
01801 case 66:
01802 /* rule 66 can match eol */
01803 YY_RULE_SETUP
01804 #line 454 "ael.flex"
01805 {
01806       char c = yytext[yyleng-1];
01807       if ( pbcpop(c))  { /* error */
01808          STORE_LOC;
01809          ast_log(LOG_ERROR,"File=%s, line=%d, column=%d: Mismatched '%c' in expression!\n",
01810             my_file, my_lineno, my_col, c);
01811          BEGIN(0);
01812          yylval->str = malloc(yyleng+1);
01813          strncpy(yylval->str, yytext, yyleng);
01814          yylval->str[yyleng] = 0;
01815          return word;
01816       }
01817       yymore();
01818    }
01819    YY_BREAK
01820 /*
01821     * handlers for arguments to a macro or application calls.
01822     * We enter this context when we find the initial '(' and
01823     * stay here until we close all matching parentheses,
01824     * and find the comma (argument separator) or the closing ')'
01825     * of the (external) call, which happens when parencount == 0
01826     * before the decrement.
01827     */
01828 case 67:
01829 /* rule 67 can match eol */
01830 YY_RULE_SETUP
01831 #line 478 "ael.flex"
01832 {
01833       char c = yytext[yyleng-1];
01834       if (c == '(')
01835          parencount++;
01836       pbcpush(c);
01837       yymore();
01838    }
01839    YY_BREAK
01840 case 68:
01841 /* rule 68 can match eol */
01842 YY_RULE_SETUP
01843 #line 486 "ael.flex"
01844 {
01845       if ( pbcpop(')') ) { /* error */
01846          STORE_LOC;
01847          ast_log(LOG_ERROR,"File=%s, line=%d, column=%d: Mismatched ')' in expression!\n", my_file, my_lineno, my_col);
01848          BEGIN(0);
01849          yylval->str = malloc(yyleng+1);
01850          strncpy(yylval->str, yytext, yyleng);
01851          yylval->str[yyleng] = 0;
01852          return word;
01853       }
01854 
01855       parencount--;
01856       if( parencount >= 0){
01857          yymore();
01858       } else {
01859          STORE_LOC;
01860          BEGIN(0);
01861          if ( !strcmp(yytext, ")") )
01862             return RP;
01863          yylval->str = malloc(yyleng);
01864          strncpy(yylval->str, yytext, yyleng);
01865          yylval->str[yyleng-1] = '\0'; /* trim trailing ')' */
01866          unput(')');
01867          return word;
01868       }
01869    }
01870    YY_BREAK
01871 case 69:
01872 /* rule 69 can match eol */
01873 YY_RULE_SETUP
01874 #line 513 "ael.flex"
01875 {
01876       if( parencount != 0) { /* ast_log(LOG_NOTICE,"Folding in a comma!\n"); */
01877          yymore();
01878       } else  {
01879          STORE_LOC;
01880          if( !strcmp(yytext,"," ) )
01881             return COMMA;
01882          yylval->str = malloc(yyleng);
01883          strncpy(yylval->str, yytext, yyleng);
01884          yylval->str[yyleng-1] = '\0'; /* trim trailing ',' */
01885          unput(',');
01886          return word;
01887       }
01888    }
01889    YY_BREAK
01890 case 70:
01891 /* rule 70 can match eol */
01892 YY_RULE_SETUP
01893 #line 528 "ael.flex"
01894 {
01895       char c = yytext[yyleng-1];
01896       if ( pbcpop(c) ) { /* error */
01897          STORE_LOC;
01898          ast_log(LOG_ERROR,"File=%s, line=%d, column=%d: Mismatched '%c' in expression!\n", my_file, my_lineno, my_col, c);
01899          BEGIN(0);
01900          yylval->str = malloc(yyleng+1);
01901          strncpy(yylval->str, yytext, yyleng);
01902          yylval->str[yyleng] = '\0';
01903          return word;
01904       }
01905       yymore();
01906    }
01907    YY_BREAK
01908 /*
01909     * context used to find tokens in the right hand side of assignments,
01910     * or in the first and second operand of a 'for'. As above, match
01911     * commas and use ';' as a separator (hence return it as a separate token).
01912     */
01913 case 71:
01914 /* rule 71 can match eol */
01915 YY_RULE_SETUP
01916 #line 547 "ael.flex"
01917 {
01918       char c = yytext[yyleng-1];
01919       yymore();
01920       pbcpush(c);
01921    }
01922    YY_BREAK
01923 case 72:
01924 /* rule 72 can match eol */
01925 YY_RULE_SETUP
01926 #line 553 "ael.flex"
01927 {
01928       char c = yytext[yyleng-1];
01929       if ( pbcpop(c) ) { /* error */
01930          STORE_LOC;
01931          ast_log(LOG_ERROR,"File=%s, line=%d, column=%d: Mismatched '%c' in expression!\n", my_file, my_lineno, my_col, c);
01932          BEGIN(0);
01933          yylval->str = malloc(yyleng+1);
01934          strncpy(yylval->str, yytext, yyleng);
01935          yylval->str[yyleng] = '\0';
01936          return word;
01937       }
01938       yymore();
01939    }
01940    YY_BREAK
01941 case 73:
01942 /* rule 73 can match eol */
01943 YY_RULE_SETUP
01944 #line 567 "ael.flex"
01945 {
01946       STORE_LOC;
01947       yylval->str = malloc(yyleng);
01948       strncpy(yylval->str, yytext, yyleng);
01949       yylval->str[yyleng-1] = '\0'; /* trim trailing ';' */
01950       unput(';');
01951       BEGIN(0);
01952       return word;
01953    }
01954    YY_BREAK
01955 case 74:
01956 /* rule 74 can match eol */
01957 YY_RULE_SETUP
01958 #line 577 "ael.flex"
01959 {
01960       char fnamebuf[1024],*p1,*p2;
01961       int glob_ret;
01962       glob_t globbuf;        /* the current globbuf */
01963       int globbuf_pos = -1;   /* where we are in the current globbuf */
01964       globbuf.gl_offs = 0; /* initialize it to silence gcc */
01965       
01966       p1 = strchr(yytext,'"');
01967       p2 = strrchr(yytext,'"');
01968       if ( include_stack_index >= MAX_INCLUDE_DEPTH ) {
01969          ast_log(LOG_ERROR,"File=%s, line=%d, column=%d: Includes nested too deeply! Wow!!! How did you do that?\n", my_file, my_lineno, my_col);
01970       } else if ( (int)(p2-p1) > sizeof(fnamebuf) - 1 ) {
01971          ast_log(LOG_ERROR,"File=%s, line=%d, column=%d: Filename is incredibly way too long (%d chars!). Inclusion ignored!\n", my_file, my_lineno, my_col, yyleng - 10);
01972       } else {
01973          strncpy(fnamebuf, p1+1, p2-p1-1);
01974          fnamebuf[p2-p1-1] = 0;
01975       if (fnamebuf[0] != '/') {
01976          char fnamebuf2[1024];
01977          snprintf(fnamebuf2,sizeof(fnamebuf2), "%s/%s", (char *)ast_config_AST_CONFIG_DIR, fnamebuf);
01978          ast_copy_string(fnamebuf,fnamebuf2,sizeof(fnamebuf));
01979       }
01980 #ifdef SOLARIS
01981          glob_ret = glob(fnamebuf, GLOB_NOCHECK, NULL, &globbuf);
01982 #else
01983          glob_ret = glob(fnamebuf, GLOB_NOMAGIC|GLOB_BRACE, NULL, &globbuf);
01984 #endif
01985          if (glob_ret == GLOB_NOSPACE) {
01986             ast_log(LOG_WARNING,
01987                "Glob Expansion of pattern '%s' failed: Not enough memory\n", fnamebuf);
01988          } else if (glob_ret  == GLOB_ABORTED) {
01989             ast_log(LOG_WARNING,
01990                "Glob Expansion of pattern '%s' failed: Read error\n", fnamebuf);
01991          } else if (glob_ret  == GLOB_NOMATCH) {
01992             ast_log(LOG_WARNING,
01993                "Glob Expansion of pattern '%s' failed: No matches!\n", fnamebuf);
01994          } else {
01995            globbuf_pos = 0;
01996          }
01997       }
01998       if (globbuf_pos > -1) {
01999          setup_filestack(fnamebuf, sizeof(fnamebuf), &globbuf, 0, yyscanner, 1);
02000       }
02001    }
02002    YY_BREAK
02003 case YY_STATE_EOF(INITIAL):
02004 case YY_STATE_EOF(paren):
02005 case YY_STATE_EOF(semic):
02006 case YY_STATE_EOF(argg):
02007 case YY_STATE_EOF(comment):
02008 case YY_STATE_EOF(curlystate):
02009 case YY_STATE_EOF(wordstate):
02010 case YY_STATE_EOF(brackstate):
02011 #line 622 "ael.flex"
02012 {
02013       char fnamebuf[2048];
02014       if (include_stack_index > 0 && include_stack[include_stack_index-1].globbuf_pos < include_stack[include_stack_index-1].globbuf.gl_pathc-1) {
02015          ael_yy_delete_buffer(YY_CURRENT_BUFFER,yyscanner );
02016          include_stack[include_stack_index-1].globbuf_pos++;
02017          setup_filestack(fnamebuf, sizeof(fnamebuf), &include_stack[include_stack_index-1].globbuf, include_stack[include_stack_index-1].globbuf_pos, yyscanner, 0);
02018          /* finish this */       
02019          
02020       } else {
02021          if (include_stack[include_stack_index].fname) {
02022             free(include_stack[include_stack_index].fname);
02023             include_stack[include_stack_index].fname = 0;
02024          }
02025          if (my_file) {
02026             free(my_file);
02027             my_file = 0;
02028          }
02029          if ( --include_stack_index < 0 ) {
02030             yyterminate();
02031          } else {
02032             globfree(&include_stack[include_stack_index].globbuf);
02033             include_stack[include_stack_index].globbuf_pos = -1;
02034             
02035             ael_yy_delete_buffer(YY_CURRENT_BUFFER,yyscanner );
02036             ael_yy_switch_to_buffer(include_stack[include_stack_index].bufstate,yyscanner );
02037             my_lineno = include_stack[include_stack_index].lineno;
02038             my_col    = include_stack[include_stack_index].colno;
02039             my_file   = strdup(include_stack[include_stack_index].fname);
02040          }
02041       }
02042    }
02043    YY_BREAK
02044 case 75:
02045 /* rule 75 can match eol */
02046 YY_RULE_SETUP
02047 #line 654 "ael.flex"
02048 { /* default rule */ ast_log(LOG_ERROR,"Unhandled char(s): %s\n", yytext); }
02049    YY_BREAK
02050 case 76:
02051 YY_RULE_SETUP
02052 #line 656 "ael.flex"
02053 YY_FATAL_ERROR( "flex scanner jammed" );
02054    YY_BREAK
02055 #line 2053 "ael_lex.c"
02056 
02057    case YY_END_OF_BUFFER:
02058       {
02059       /* Amount of text matched not including the EOB char. */
02060       int yy_amount_of_matched_text = (int) (yy_cp - yyg->yytext_ptr) - 1;
02061 
02062       /* Undo the effects of YY_DO_BEFORE_ACTION. */
02063       *yy_cp = yyg->yy_hold_char;
02064       YY_RESTORE_YY_MORE_OFFSET
02065 
02066       if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW )
02067          {
02068          /* We're scanning a new file or input source.  It's
02069           * possible that this happened because the user
02070           * just pointed yyin at a new source and called
02071           * ael_yylex().  If so, then we have to assure
02072           * consistency between YY_CURRENT_BUFFER and our
02073           * globals.  Here is the right place to do so, because
02074           * this is the first action (other than possibly a
02075           * back-up) that will match for the new input source.
02076           */
02077          yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
02078          YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin;
02079          YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL;
02080          }
02081 
02082       /* Note that here we test for yy_c_buf_p "<=" to the position
02083        * of the first EOB in the buffer, since yy_c_buf_p will
02084        * already have been incremented past the NUL character
02085        * (since all states make transitions on EOB to the
02086        * end-of-buffer state).  Contrast this with the test
02087        * in input().
02088        */
02089       if ( yyg->yy_c_buf_p <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
02090          { /* This was really a NUL. */
02091          yy_state_type yy_next_state;
02092 
02093          yyg->yy_c_buf_p = yyg->yytext_ptr + yy_amount_of_matched_text;
02094 
02095          yy_current_state = yy_get_previous_state( yyscanner );
02096 
02097          /* Okay, we're now positioned to make the NUL
02098           * transition.  We couldn't have
02099           * yy_get_previous_state() go ahead and do it
02100           * for us because it doesn't know how to deal
02101           * with the possibility of jamming (and we don't
02102           * want to build jamming into it because then it
02103           * will run more slowly).
02104           */
02105 
02106          yy_next_state = yy_try_NUL_trans( yy_current_state , yyscanner);
02107 
02108          yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
02109 
02110          if ( yy_next_state )
02111             {
02112             /* Consume the NUL. */
02113             yy_cp = ++yyg->yy_c_buf_p;
02114             yy_current_state = yy_next_state;
02115             goto yy_match;
02116             }
02117 
02118          else
02119             {
02120             yy_cp = yyg->yy_last_accepting_cpos;
02121             yy_current_state = yyg->yy_last_accepting_state;
02122             goto yy_find_action;
02123             }
02124          }
02125 
02126       else switch ( yy_get_next_buffer( yyscanner ) )
02127          {
02128          case EOB_ACT_END_OF_FILE:
02129             {
02130             yyg->yy_did_buffer_switch_on_eof = 0;
02131 
02132             if ( ael_yywrap(yyscanner ) )
02133                {
02134                /* Note: because we've taken care in
02135                 * yy_get_next_buffer() to have set up
02136                 * yytext, we can now set up
02137                 * yy_c_buf_p so that if some total
02138                 * hoser (like flex itself) wants to
02139                 * call the scanner after we return the
02140                 * YY_NULL, it'll still work - another
02141                 * YY_NULL will get returned.
02142                 */
02143                yyg->yy_c_buf_p = yyg->yytext_ptr + YY_MORE_ADJ;
02144 
02145                yy_act = YY_STATE_EOF(YY_START);
02146                goto do_action;
02147                }
02148 
02149             else
02150                {
02151                if ( ! yyg->yy_did_buffer_switch_on_eof )
02152                   YY_NEW_FILE;
02153                }
02154             break;
02155             }
02156 
02157          case EOB_ACT_CONTINUE_SCAN:
02158             yyg->yy_c_buf_p =
02159                yyg->yytext_ptr + yy_amount_of_matched_text;
02160 
02161             yy_current_state = yy_get_previous_state( yyscanner );
02162 
02163             yy_cp = yyg->yy_c_buf_p;
02164             yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
02165             goto yy_match;
02166 
02167          case EOB_ACT_LAST_MATCH:
02168             yyg->yy_c_buf_p =
02169             &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars];
02170 
02171             yy_current_state = yy_get_previous_state( yyscanner );
02172 
02173             yy_cp = yyg->yy_c_buf_p;
02174             yy_bp = yyg->yytext_ptr + YY_MORE_ADJ;
02175             goto yy_find_action;
02176          }
02177       break;
02178       }
02179 
02180    default:
02181       YY_FATAL_ERROR(
02182          "fatal flex scanner internal error--no action found" );
02183    } /* end of action switch */
02184       } /* end of scanning one token */
02185 } /* end of ael_yylex */
02186 
02187 /* yy_get_next_buffer - try to read in a new buffer
02188  *
02189  * Returns a code representing an action:
02190  * EOB_ACT_LAST_MATCH -
02191  * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
02192  * EOB_ACT_END_OF_FILE - end of file
02193  */
02194 static int yy_get_next_buffer (yyscan_t yyscanner)
02195 {
02196     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02197    register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
02198    register char *source = yyg->yytext_ptr;
02199    register int number_to_move, i;
02200    int ret_val;
02201 
02202    if ( yyg->yy_c_buf_p > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] )
02203       YY_FATAL_ERROR(
02204       "fatal flex scanner internal error--end of buffer missed" );
02205 
02206    if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
02207       { /* Don't try to fill the buffer, so this is an EOF. */
02208       if ( yyg->yy_c_buf_p - yyg->yytext_ptr - YY_MORE_ADJ == 1 )
02209          {
02210          /* We matched a single character, the EOB, so
02211           * treat this as a final EOF.
02212           */
02213          return EOB_ACT_END_OF_FILE;
02214          }
02215 
02216       else
02217          {
02218          /* We matched some text prior to the EOB, first
02219           * process it.
02220           */
02221          return EOB_ACT_LAST_MATCH;
02222          }
02223       }
02224 
02225    /* Try to read more data. */
02226 
02227    /* First move last chars to start of buffer. */
02228    number_to_move = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr) - 1;
02229 
02230    for ( i = 0; i < number_to_move; ++i )
02231       *(dest++) = *(source++);
02232 
02233    if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
02234       /* don't do the read, it's not guaranteed to return an EOF,
02235        * just force an EOF
02236        */
02237       YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars = 0;
02238 
02239    else
02240       {
02241          int num_to_read =
02242          YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
02243 
02244       while ( num_to_read <= 0 )
02245          { /* Not enough room in the buffer - grow it. */
02246 
02247          /* just a shorter name for the current buffer */
02248          YY_BUFFER_STATE b = YY_CURRENT_BUFFER;
02249 
02250          int yy_c_buf_p_offset =
02251             (int) (yyg->yy_c_buf_p - b->yy_ch_buf);
02252 
02253          if ( b->yy_is_our_buffer )
02254             {
02255             int new_size = b->yy_buf_size * 2;
02256 
02257             if ( new_size <= 0 )
02258                b->yy_buf_size += b->yy_buf_size / 8;
02259             else
02260                b->yy_buf_size *= 2;
02261 
02262             b->yy_ch_buf = (char *)
02263                /* Include room in for 2 EOB chars. */
02264                ael_yyrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ,yyscanner );
02265             }
02266          else
02267             /* Can't grow it, we don't own it. */
02268             b->yy_ch_buf = 0;
02269 
02270          if ( ! b->yy_ch_buf )
02271             YY_FATAL_ERROR(
02272             "fatal error - scanner input buffer overflow" );
02273 
02274          yyg->yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset];
02275 
02276          num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size -
02277                   number_to_move - 1;
02278 
02279          }
02280 
02281       if ( num_to_read > YY_READ_BUF_SIZE )
02282          num_to_read = YY_READ_BUF_SIZE;
02283 
02284       /* Read in more data. */
02285       YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
02286          yyg->yy_n_chars, (size_t) num_to_read );
02287 
02288       YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
02289       }
02290 
02291    if ( yyg->yy_n_chars == 0 )
02292       {
02293       if ( number_to_move == YY_MORE_ADJ )
02294          {
02295          ret_val = EOB_ACT_END_OF_FILE;
02296          ael_yyrestart(yyin  ,yyscanner);
02297          }
02298 
02299       else
02300          {
02301          ret_val = EOB_ACT_LAST_MATCH;
02302          YY_CURRENT_BUFFER_LVALUE->yy_buffer_status =
02303             YY_BUFFER_EOF_PENDING;
02304          }
02305       }
02306 
02307    else
02308       ret_val = EOB_ACT_CONTINUE_SCAN;
02309 
02310    if ((yy_size_t) (yyg->yy_n_chars + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
02311       /* Extend the array by 50%, plus the number we really need. */
02312       yy_size_t new_size = yyg->yy_n_chars + number_to_move + (yyg->yy_n_chars >> 1);
02313       YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) ael_yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ,yyscanner );
02314       if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
02315          YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
02316    }
02317 
02318    yyg->yy_n_chars += number_to_move;
02319    YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] = YY_END_OF_BUFFER_CHAR;
02320    YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
02321 
02322    yyg->yytext_ptr = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
02323 
02324    return ret_val;
02325 }
02326 
02327 /* yy_get_previous_state - get the state just before the EOB char was reached */
02328 
02329     static yy_state_type yy_get_previous_state (yyscan_t yyscanner)
02330 {
02331    register yy_state_type yy_current_state;
02332    register char *yy_cp;
02333     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02334 
02335    yy_current_state = yyg->yy_start;
02336 
02337    for ( yy_cp = yyg->yytext_ptr + YY_MORE_ADJ; yy_cp < yyg->yy_c_buf_p; ++yy_cp )
02338       {
02339       register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1);
02340       if ( yy_accept[yy_current_state] )
02341          {
02342          yyg->yy_last_accepting_state = yy_current_state;
02343          yyg->yy_last_accepting_cpos = yy_cp;
02344          }
02345       while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
02346          {
02347          yy_current_state = (int) yy_def[yy_current_state];
02348          if ( yy_current_state >= 285 )
02349             yy_c = yy_meta[(unsigned int) yy_c];
02350          }
02351       yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
02352       }
02353 
02354    return yy_current_state;
02355 }
02356 
02357 /* yy_try_NUL_trans - try to make a transition on the NUL character
02358  *
02359  * synopsis
02360  * next_state = yy_try_NUL_trans( current_state );
02361  */
02362     static yy_state_type yy_try_NUL_trans  (yy_state_type yy_current_state , yyscan_t yyscanner)
02363 {
02364    register int yy_is_jam;
02365     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* This var may be unused depending upon options. */
02366    register char *yy_cp = yyg->yy_c_buf_p;
02367 
02368    register YY_CHAR yy_c = 1;
02369    if ( yy_accept[yy_current_state] )
02370       {
02371       yyg->yy_last_accepting_state = yy_current_state;
02372       yyg->yy_last_accepting_cpos = yy_cp;
02373       }
02374    while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
02375       {
02376       yy_current_state = (int) yy_def[yy_current_state];
02377       if ( yy_current_state >= 285 )
02378          yy_c = yy_meta[(unsigned int) yy_c];
02379       }
02380    yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
02381    yy_is_jam = (yy_current_state == 284);
02382 
02383    return yy_is_jam ? 0 : yy_current_state;
02384 }
02385 
02386     static void yyunput (int c, register char * yy_bp , yyscan_t yyscanner)
02387 {
02388    register char *yy_cp;
02389     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02390 
02391     yy_cp = yyg->yy_c_buf_p;
02392 
02393    /* undo effects of setting up yytext */
02394    *yy_cp = yyg->yy_hold_char;
02395 
02396    if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
02397       { /* need to shift things up to make room */
02398       /* +2 for EOB chars. */
02399       register int number_to_move = yyg->yy_n_chars + 2;
02400       register char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[
02401                YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2];
02402       register char *source =
02403             &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move];
02404 
02405       while ( source > YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
02406          *--dest = *--source;
02407 
02408       yy_cp += (int) (dest - source);
02409       yy_bp += (int) (dest - source);
02410       YY_CURRENT_BUFFER_LVALUE->yy_n_chars =
02411          yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_buf_size;
02412 
02413       if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
02414          YY_FATAL_ERROR( "flex scanner push-back overflow" );
02415       }
02416 
02417    *--yy_cp = (char) c;
02418 
02419    yyg->yytext_ptr = yy_bp;
02420    yyg->yy_hold_char = *yy_cp;
02421    yyg->yy_c_buf_p = yy_cp;
02422 }
02423 
02424 #ifndef YY_NO_INPUT
02425 #ifdef __cplusplus
02426     static int yyinput (yyscan_t yyscanner)
02427 #else
02428     static int input  (yyscan_t yyscanner)
02429 #endif
02430 
02431 {
02432    int c;
02433     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02434 
02435    *yyg->yy_c_buf_p = yyg->yy_hold_char;
02436 
02437    if ( *yyg->yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
02438       {
02439       /* yy_c_buf_p now points to the character we want to return.
02440        * If this occurs *before* the EOB characters, then it's a
02441        * valid NUL; if not, then we've hit the end of the buffer.
02442        */
02443       if ( yyg->yy_c_buf_p < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] )
02444          /* This was really a NUL. */
02445          *yyg->yy_c_buf_p = '\0';
02446 
02447       else
02448          { /* need more input */
02449          int offset = yyg->yy_c_buf_p - yyg->yytext_ptr;
02450          ++yyg->yy_c_buf_p;
02451 
02452          switch ( yy_get_next_buffer( yyscanner ) )
02453             {
02454             case EOB_ACT_LAST_MATCH:
02455                /* This happens because yy_g_n_b()
02456                 * sees that we've accumulated a
02457                 * token and flags that we need to
02458                 * try matching the token before
02459                 * proceeding.  But for input(),
02460                 * there's no matching to consider.
02461                 * So convert the EOB_ACT_LAST_MATCH
02462                 * to EOB_ACT_END_OF_FILE.
02463                 */
02464 
02465                /* Reset buffer status. */
02466                ael_yyrestart(yyin ,yyscanner);
02467 
02468                /*FALLTHROUGH*/
02469 
02470             case EOB_ACT_END_OF_FILE:
02471                {
02472                if ( ael_yywrap(yyscanner ) )
02473                   return EOF;
02474 
02475                if ( ! yyg->yy_did_buffer_switch_on_eof )
02476                   YY_NEW_FILE;
02477 #ifdef __cplusplus
02478                return yyinput(yyscanner);
02479 #else
02480                return input(yyscanner);
02481 #endif
02482                }
02483 
02484             case EOB_ACT_CONTINUE_SCAN:
02485                yyg->yy_c_buf_p = yyg->yytext_ptr + offset;
02486                break;
02487             }
02488          }
02489       }
02490 
02491    c = *(unsigned char *) yyg->yy_c_buf_p;   /* cast for 8-bit char's */
02492    *yyg->yy_c_buf_p = '\0';   /* preserve yytext */
02493    yyg->yy_hold_char = *++yyg->yy_c_buf_p;
02494 
02495    return c;
02496 }
02497 #endif   /* ifndef YY_NO_INPUT */
02498 
02499 /** Immediately switch to a different input stream.
02500  * @param input_file A readable stream.
02501  * @param yyscanner The scanner object.
02502  * @note This function does not reset the start condition to @c INITIAL .
02503  */
02504     void ael_yyrestart  (FILE * input_file , yyscan_t yyscanner)
02505 {
02506     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02507 
02508    if ( ! YY_CURRENT_BUFFER ){
02509         ael_yyensure_buffer_stack (yyscanner);
02510       YY_CURRENT_BUFFER_LVALUE =
02511             ael_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner);
02512    }
02513 
02514    ael_yy_init_buffer(YY_CURRENT_BUFFER,input_file ,yyscanner);
02515    ael_yy_load_buffer_state(yyscanner );
02516 }
02517 
02518 /** Switch to a different input buffer.
02519  * @param new_buffer The new input buffer.
02520  * @param yyscanner The scanner object.
02521  */
02522     void ael_yy_switch_to_buffer  (YY_BUFFER_STATE  new_buffer , yyscan_t yyscanner)
02523 {
02524     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02525 
02526    /* TODO. We should be able to replace this entire function body
02527     * with
02528     *    ael_yypop_buffer_state();
02529     *    ael_yypush_buffer_state(new_buffer);
02530      */
02531    ael_yyensure_buffer_stack (yyscanner);
02532    if ( YY_CURRENT_BUFFER == new_buffer )
02533       return;
02534 
02535    if ( YY_CURRENT_BUFFER )
02536       {
02537       /* Flush out information for old buffer. */
02538       *yyg->yy_c_buf_p = yyg->yy_hold_char;
02539       YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
02540       YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
02541       }
02542 
02543    YY_CURRENT_BUFFER_LVALUE = new_buffer;
02544    ael_yy_load_buffer_state(yyscanner );
02545 
02546    /* We don't actually know whether we did this switch during
02547     * EOF (ael_yywrap()) processing, but the only time this flag
02548     * is looked at is after ael_yywrap() is called, so it's safe
02549     * to go ahead and always set it.
02550     */
02551    yyg->yy_did_buffer_switch_on_eof = 1;
02552 }
02553 
02554 static void ael_yy_load_buffer_state  (yyscan_t yyscanner)
02555 {
02556     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02557    yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
02558    yyg->yytext_ptr = yyg->yy_c_buf_p = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos;
02559    yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file;
02560    yyg->yy_hold_char = *yyg->yy_c_buf_p;
02561 }
02562 
02563 /** Allocate and initialize an input buffer state.
02564  * @param file A readable stream.
02565  * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
02566  * @param yyscanner The scanner object.
02567  * @return the allocated buffer state.
02568  */
02569     YY_BUFFER_STATE ael_yy_create_buffer  (FILE * file, int  size , yyscan_t yyscanner)
02570 {
02571    YY_BUFFER_STATE b;
02572     
02573    b = (YY_BUFFER_STATE) ael_yyalloc(sizeof( struct yy_buffer_state ) ,yyscanner );
02574    if ( ! b )
02575       YY_FATAL_ERROR( "out of dynamic memory in ael_yy_create_buffer()" );
02576 
02577    b->yy_buf_size = size;
02578 
02579    /* yy_ch_buf has to be 2 characters longer than the size given because
02580     * we need to put in 2 end-of-buffer characters.
02581     */
02582    b->yy_ch_buf = (char *) ael_yyalloc(b->yy_buf_size + 2 ,yyscanner );
02583    if ( ! b->yy_ch_buf )
02584       YY_FATAL_ERROR( "out of dynamic memory in ael_yy_create_buffer()" );
02585 
02586    b->yy_is_our_buffer = 1;
02587 
02588    ael_yy_init_buffer(b,file ,yyscanner);
02589 
02590    return b;
02591 }
02592 
02593 /** Destroy the buffer.
02594  * @param b a buffer created with ael_yy_create_buffer()
02595  * @param yyscanner The scanner object.
02596  */
02597     void ael_yy_delete_buffer (YY_BUFFER_STATE  b , yyscan_t yyscanner)
02598 {
02599     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02600 
02601    if ( ! b )
02602       return;
02603 
02604    if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */
02605       YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
02606 
02607    if ( b->yy_is_our_buffer )
02608       ael_yyfree((void *) b->yy_ch_buf ,yyscanner );
02609 
02610    ael_yyfree((void *) b ,yyscanner );
02611 }
02612 
02613 #ifndef __cplusplus
02614 extern int isatty (int );
02615 #endif /* __cplusplus */
02616     
02617 /* Initializes or reinitializes a buffer.
02618  * This function is sometimes called more than once on the same buffer,
02619  * such as during a ael_yyrestart() or at EOF.
02620  */
02621     static void ael_yy_init_buffer  (YY_BUFFER_STATE  b, FILE * file , yyscan_t yyscanner)
02622 
02623 {
02624    int oerrno = errno;
02625     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02626 
02627    ael_yy_flush_buffer(b ,yyscanner);
02628 
02629    b->yy_input_file = file;
02630    b->yy_fill_buffer = 1;
02631 
02632     /* If b is the current buffer, then ael_yy_init_buffer was _probably_
02633      * called from ael_yyrestart() or through yy_get_next_buffer.
02634      * In that case, we don't want to reset the lineno or column.
02635      */
02636     if (b != YY_CURRENT_BUFFER){
02637         b->yy_bs_lineno = 1;
02638         b->yy_bs_column = 0;
02639     }
02640 
02641         b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0;
02642     
02643    errno = oerrno;
02644 }
02645 
02646 /** Discard all buffered characters. On the next scan, YY_INPUT will be called.
02647  * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
02648  * @param yyscanner The scanner object.
02649  */
02650     void ael_yy_flush_buffer (YY_BUFFER_STATE  b , yyscan_t yyscanner)
02651 {
02652     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02653    if ( ! b )
02654       return;
02655 
02656    b->yy_n_chars = 0;
02657 
02658    /* We always need two end-of-buffer characters.  The first causes
02659     * a transition to the end-of-buffer state.  The second causes
02660     * a jam in that state.
02661     */
02662    b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR;
02663    b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
02664 
02665    b->yy_buf_pos = &b->yy_ch_buf[0];
02666 
02667    b->yy_at_bol = 1;
02668    b->yy_buffer_status = YY_BUFFER_NEW;
02669 
02670    if ( b == YY_CURRENT_BUFFER )
02671       ael_yy_load_buffer_state(yyscanner );
02672 }
02673 
02674 /** Pushes the new state onto the stack. The new state becomes
02675  *  the current state. This function will allocate the stack
02676  *  if necessary.
02677  *  @param new_buffer The new state.
02678  *  @param yyscanner The scanner object.
02679  */
02680 void ael_yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
02681 {
02682     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02683    if (new_buffer == NULL)
02684       return;
02685 
02686    ael_yyensure_buffer_stack(yyscanner);
02687 
02688    /* This block is copied from ael_yy_switch_to_buffer. */
02689    if ( YY_CURRENT_BUFFER )
02690       {
02691       /* Flush out information for old buffer. */
02692       *yyg->yy_c_buf_p = yyg->yy_hold_char;
02693       YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p;
02694       YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
02695       }
02696 
02697    /* Only push if top exists. Otherwise, replace top. */
02698    if (YY_CURRENT_BUFFER)
02699       yyg->yy_buffer_stack_top++;
02700    YY_CURRENT_BUFFER_LVALUE = new_buffer;
02701 
02702    /* copied from ael_yy_switch_to_buffer. */
02703    ael_yy_load_buffer_state(yyscanner );
02704    yyg->yy_did_buffer_switch_on_eof = 1;
02705 }
02706 
02707 /** Removes and deletes the top of the stack, if present.
02708  *  The next element becomes the new top.
02709  *  @param yyscanner The scanner object.
02710  */
02711 void ael_yypop_buffer_state (yyscan_t yyscanner)
02712 {
02713     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02714    if (!YY_CURRENT_BUFFER)
02715       return;
02716 
02717    ael_yy_delete_buffer(YY_CURRENT_BUFFER ,yyscanner);
02718    YY_CURRENT_BUFFER_LVALUE = NULL;
02719    if (yyg->yy_buffer_stack_top > 0)
02720       --yyg->yy_buffer_stack_top;
02721 
02722    if (YY_CURRENT_BUFFER) {
02723       ael_yy_load_buffer_state(yyscanner );
02724       yyg->yy_did_buffer_switch_on_eof = 1;
02725    }
02726 }
02727 
02728 /* Allocates the stack if it does not exist.
02729  *  Guarantees space for at least one push.
02730  */
02731 static void ael_yyensure_buffer_stack (yyscan_t yyscanner)
02732 {
02733    int num_to_alloc;
02734     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02735 
02736    if (!yyg->yy_buffer_stack) {
02737 
02738       /* First allocation is just for 2 elements, since we don't know if this
02739        * scanner will even need a stack. We use 2 instead of 1 to avoid an
02740        * immediate realloc on the next call.
02741          */
02742       num_to_alloc = 1;
02743       yyg->yy_buffer_stack = (struct yy_buffer_state**)ael_yyalloc
02744                         (num_to_alloc * sizeof(struct yy_buffer_state*)
02745                         , yyscanner);
02746       if ( ! yyg->yy_buffer_stack )
02747          YY_FATAL_ERROR( "out of dynamic memory in ael_yyensure_buffer_stack()" );
02748                           
02749       memset(yyg->yy_buffer_stack, 0, num_to_alloc * sizeof(struct yy_buffer_state*));
02750             
02751       yyg->yy_buffer_stack_max = num_to_alloc;
02752       yyg->yy_buffer_stack_top = 0;
02753       return;
02754    }
02755 
02756    if (yyg->yy_buffer_stack_top >= (yyg->yy_buffer_stack_max) - 1){
02757 
02758       /* Increase the buffer to prepare for a possible push. */
02759       int grow_size = 8 /* arbitrary grow size */;
02760 
02761       num_to_alloc = yyg->yy_buffer_stack_max + grow_size;
02762       yyg->yy_buffer_stack = (struct yy_buffer_state**)ael_yyrealloc
02763                         (yyg->yy_buffer_stack,
02764                         num_to_alloc * sizeof(struct yy_buffer_state*)
02765                         , yyscanner);
02766       if ( ! yyg->yy_buffer_stack )
02767          YY_FATAL_ERROR( "out of dynamic memory in ael_yyensure_buffer_stack()" );
02768 
02769       /* zero only the new slots.*/
02770       memset(yyg->yy_buffer_stack + yyg->yy_buffer_stack_max, 0, grow_size * sizeof(struct yy_buffer_state*));
02771       yyg->yy_buffer_stack_max = num_to_alloc;
02772    }
02773 }
02774 
02775 /** Setup the input buffer state to scan directly from a user-specified character buffer.
02776  * @param base the character buffer
02777  * @param size the size in bytes of the character buffer
02778  * @param yyscanner The scanner object.
02779  * @return the newly allocated buffer state object. 
02780  */
02781 YY_BUFFER_STATE ael_yy_scan_buffer  (char * base, yy_size_t  size , yyscan_t yyscanner)
02782 {
02783    YY_BUFFER_STATE b;
02784     
02785    if ( size < 2 ||
02786         base[size-2] != YY_END_OF_BUFFER_CHAR ||
02787         base[size-1] != YY_END_OF_BUFFER_CHAR )
02788       /* They forgot to leave room for the EOB's. */
02789       return 0;
02790 
02791    b = (YY_BUFFER_STATE) ael_yyalloc(sizeof( struct yy_buffer_state ) ,yyscanner );
02792    if ( ! b )
02793       YY_FATAL_ERROR( "out of dynamic memory in ael_yy_scan_buffer()" );
02794 
02795    b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */
02796    b->yy_buf_pos = b->yy_ch_buf = base;
02797    b->yy_is_our_buffer = 0;
02798    b->yy_input_file = 0;
02799    b->yy_n_chars = b->yy_buf_size;
02800    b->yy_is_interactive = 0;
02801    b->yy_at_bol = 1;
02802    b->yy_fill_buffer = 0;
02803    b->yy_buffer_status = YY_BUFFER_NEW;
02804 
02805    ael_yy_switch_to_buffer(b ,yyscanner );
02806 
02807    return b;
02808 }
02809 
02810 /** Setup the input buffer state to scan a string. The next call to ael_yylex() will
02811  * scan from a @e copy of @a str.
02812  * @param yystr a NUL-terminated string to scan
02813  * @param yyscanner The scanner object.
02814  * @return the newly allocated buffer state object.
02815  * @note If you want to scan bytes that may contain NUL values, then use
02816  *       ael_yy_scan_bytes() instead.
02817  */
02818 YY_BUFFER_STATE ael_yy_scan_string (yyconst char * yystr , yyscan_t yyscanner)
02819 {
02820     
02821    return ael_yy_scan_bytes(yystr,strlen(yystr) ,yyscanner);
02822 }
02823 
02824 /** Setup the input buffer state to scan the given bytes. The next call to ael_yylex() will
02825  * scan from a @e copy of @a bytes.
02826  * @param yybytes the byte buffer to scan
02827  * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes.
02828  * @param yyscanner The scanner object.
02829  * @return the newly allocated buffer state object.
02830  */
02831 YY_BUFFER_STATE ael_yy_scan_bytes  (yyconst char * yybytes, int  _yybytes_len , yyscan_t yyscanner)
02832 {
02833    YY_BUFFER_STATE b;
02834    char *buf;
02835    yy_size_t n;
02836    int i;
02837     
02838    /* Get memory for full buffer, including space for trailing EOB's. */
02839    n = _yybytes_len + 2;
02840    buf = (char *) ael_yyalloc(n ,yyscanner );
02841    if ( ! buf )
02842       YY_FATAL_ERROR( "out of dynamic memory in ael_yy_scan_bytes()" );
02843 
02844    for ( i = 0; i < _yybytes_len; ++i )
02845       buf[i] = yybytes[i];
02846 
02847    buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
02848 
02849    b = ael_yy_scan_buffer(buf,n ,yyscanner);
02850    if ( ! b )
02851       YY_FATAL_ERROR( "bad buffer in ael_yy_scan_bytes()" );
02852 
02853    /* It's okay to grow etc. this buffer, and we should throw it
02854     * away when we're done.
02855     */
02856    b->yy_is_our_buffer = 1;
02857 
02858    return b;
02859 }
02860 
02861 #ifndef YY_EXIT_FAILURE
02862 #define YY_EXIT_FAILURE 2
02863 #endif
02864 
02865 static void yy_fatal_error (yyconst char* msg , yyscan_t yyscanner)
02866 {
02867       (void) fprintf( stderr, "%s\n", msg );
02868    exit( YY_EXIT_FAILURE );
02869 }
02870 
02871 /* Redefine yyless() so it works in section 3 code. */
02872 
02873 #undef yyless
02874 #define yyless(n) \
02875    do \
02876       { \
02877       /* Undo effects of setting up yytext. */ \
02878         int yyless_macro_arg = (n); \
02879         YY_LESS_LINENO(yyless_macro_arg);\
02880       yytext[yyleng] = yyg->yy_hold_char; \
02881       yyg->yy_c_buf_p = yytext + yyless_macro_arg; \
02882       yyg->yy_hold_char = *yyg->yy_c_buf_p; \
02883       *yyg->yy_c_buf_p = '\0'; \
02884       yyleng = yyless_macro_arg; \
02885       } \
02886    while ( 0 )
02887 
02888 /* Accessor  methods (get/set functions) to struct members. */
02889 
02890 /** Get the user-defined data for this scanner.
02891  * @param yyscanner The scanner object.
02892  */
02893 YY_EXTRA_TYPE ael_yyget_extra  (yyscan_t yyscanner)
02894 {
02895     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02896     return yyextra;
02897 }
02898 
02899 /** Get the current line number.
02900  * @param yyscanner The scanner object.
02901  */
02902 int ael_yyget_lineno  (yyscan_t yyscanner)
02903 {
02904     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02905     
02906         if (! YY_CURRENT_BUFFER)
02907             return 0;
02908     
02909     return yylineno;
02910 }
02911 
02912 /** Get the current column number.
02913  * @param yyscanner The scanner object.
02914  */
02915 int ael_yyget_column  (yyscan_t yyscanner)
02916 {
02917     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02918     
02919         if (! YY_CURRENT_BUFFER)
02920             return 0;
02921     
02922     return yycolumn;
02923 }
02924 
02925 /** Get the input stream.
02926  * @param yyscanner The scanner object.
02927  */
02928 FILE *ael_yyget_in  (yyscan_t yyscanner)
02929 {
02930     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02931     return yyin;
02932 }
02933 
02934 /** Get the output stream.
02935  * @param yyscanner The scanner object.
02936  */
02937 FILE *ael_yyget_out  (yyscan_t yyscanner)
02938 {
02939     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02940     return yyout;
02941 }
02942 
02943 /** Get the length of the current token.
02944  * @param yyscanner The scanner object.
02945  */
02946 int ael_yyget_leng  (yyscan_t yyscanner)
02947 {
02948     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02949     return yyleng;
02950 }
02951 
02952 /** Get the current token.
02953  * @param yyscanner The scanner object.
02954  */
02955 
02956 char *ael_yyget_text  (yyscan_t yyscanner)
02957 {
02958     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02959     return yytext;
02960 }
02961 
02962 /** Set the user-defined data. This data is never touched by the scanner.
02963  * @param user_defined The data to be associated with this scanner.
02964  * @param yyscanner The scanner object.
02965  */
02966 void ael_yyset_extra (YY_EXTRA_TYPE  user_defined , yyscan_t yyscanner)
02967 {
02968     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02969     yyextra = user_defined ;
02970 }
02971 
02972 /** Set the current line number.
02973  * @param line_number
02974  * @param yyscanner The scanner object.
02975  */
02976 void ael_yyset_lineno (int  line_number , yyscan_t yyscanner)
02977 {
02978     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02979 
02980         /* lineno is only valid if an input buffer exists. */
02981         if (! YY_CURRENT_BUFFER )
02982            yy_fatal_error( "ael_yyset_lineno called with no buffer" , yyscanner); 
02983     
02984     yylineno = line_number;
02985 }
02986 
02987 /** Set the current column.
02988  * @param line_number
02989  * @param yyscanner The scanner object.
02990  */
02991 void ael_yyset_column (int  column_no , yyscan_t yyscanner)
02992 {
02993     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
02994 
02995         /* column is only valid if an input buffer exists. */
02996         if (! YY_CURRENT_BUFFER )
02997            yy_fatal_error( "ael_yyset_column called with no buffer" , yyscanner); 
02998     
02999     yycolumn = column_no;
03000 }
03001 
03002 /** Set the input stream. This does not discard the current
03003  * input buffer.
03004  * @param in_str A readable stream.
03005  * @param yyscanner The scanner object.
03006  * @see ael_yy_switch_to_buffer
03007  */
03008 void ael_yyset_in (FILE *  in_str , yyscan_t yyscanner)
03009 {
03010     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
03011     yyin = in_str ;
03012 }
03013 
03014 void ael_yyset_out (FILE *  out_str , yyscan_t yyscanner)
03015 {
03016     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
03017     yyout = out_str ;
03018 }
03019 
03020 int ael_yyget_debug  (yyscan_t yyscanner)
03021 {
03022     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
03023     return yy_flex_debug;
03024 }
03025 
03026 void ael_yyset_debug (int  bdebug , yyscan_t yyscanner)
03027 {
03028     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
03029     yy_flex_debug = bdebug ;
03030 }
03031 
03032 /* Accessor methods for yylval and yylloc */
03033 
03034 YYSTYPE * ael_yyget_lval  (yyscan_t yyscanner)
03035 {
03036     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
03037     return yylval;
03038 }
03039 
03040 void ael_yyset_lval (YYSTYPE *  yylval_param , yyscan_t yyscanner)
03041 {
03042     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
03043     yylval = yylval_param;
03044 }
03045 
03046 YYLTYPE *ael_yyget_lloc  (yyscan_t yyscanner)
03047 {
03048     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
03049     return yylloc;
03050 }
03051     
03052 void ael_yyset_lloc (YYLTYPE *  yylloc_param , yyscan_t yyscanner)
03053 {
03054     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
03055     yylloc = yylloc_param;
03056 }
03057     
03058 /* User-visible API */
03059 
03060 /* ael_yylex_init is special because it creates the scanner itself, so it is
03061  * the ONLY reentrant function that doesn't take the scanner as the last argument.
03062  * That's why we explicitly handle the declaration, instead of using our macros.
03063  */
03064 
03065 int ael_yylex_init(yyscan_t* ptr_yy_globals)
03066 
03067 {
03068     if (ptr_yy_globals == NULL){
03069         errno = EINVAL;
03070         return 1;
03071     }
03072 
03073     *ptr_yy_globals = (yyscan_t) ael_yyalloc ( sizeof( struct yyguts_t ), NULL );
03074 
03075     if (*ptr_yy_globals == NULL){
03076         errno = ENOMEM;
03077         return 1;
03078     }
03079 
03080     /* By setting to 0xAA, we expose bugs in yy_init_globals. Leave at 0x00 for releases. */
03081     memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
03082 
03083     return yy_init_globals ( *ptr_yy_globals );
03084 }
03085 
03086 /* ael_yylex_init_extra has the same functionality as ael_yylex_init, but follows the
03087  * convention of taking the scanner as the last argument. Note however, that
03088  * this is a *pointer* to a scanner, as it will be allocated by this call (and
03089  * is the reason, too, why this function also must handle its own declaration).
03090  * The user defined value in the first argument will be available to ael_yyalloc in
03091  * the yyextra field.
03092  */
03093 
03094 int ael_yylex_init_extra(YY_EXTRA_TYPE yy_user_defined,yyscan_t* ptr_yy_globals )
03095 
03096 {
03097     struct yyguts_t dummy_yyguts;
03098 
03099     ael_yyset_extra (yy_user_defined, &dummy_yyguts);
03100 
03101     if (ptr_yy_globals == NULL){
03102         errno = EINVAL;
03103         return 1;
03104     }
03105    
03106     *ptr_yy_globals = (yyscan_t) ael_yyalloc ( sizeof( struct yyguts_t ), &dummy_yyguts );
03107    
03108     if (*ptr_yy_globals == NULL){
03109         errno = ENOMEM;
03110         return 1;
03111     }
03112     
03113     /* By setting to 0xAA, we expose bugs in
03114     yy_init_globals. Leave at 0x00 for releases. */
03115     memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
03116     
03117     ael_yyset_extra (yy_user_defined, *ptr_yy_globals);
03118     
03119     return yy_init_globals ( *ptr_yy_globals );
03120 }
03121 
03122 static int yy_init_globals (yyscan_t yyscanner)
03123 {
03124     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
03125     /* Initialization is the same as for the non-reentrant scanner.
03126      * This function is called from ael_yylex_destroy(), so don't allocate here.
03127      */
03128 
03129     yyg->yy_buffer_stack = 0;
03130     yyg->yy_buffer_stack_top = 0;
03131     yyg->yy_buffer_stack_max = 0;
03132     yyg->yy_c_buf_p = (char *) 0;
03133     yyg->yy_init = 0;
03134     yyg->yy_start = 0;
03135 
03136     yyg->yy_start_stack_ptr = 0;
03137     yyg->yy_start_stack_depth = 0;
03138     yyg->yy_start_stack =  NULL;
03139 
03140 /* Defined in main.c */
03141 #ifdef YY_STDINIT
03142     yyin = stdin;
03143     yyout = stdout;
03144 #else
03145     yyin = (FILE *) 0;
03146     yyout = (FILE *) 0;
03147 #endif
03148 
03149     /* For future reference: Set errno on error, since we are called by
03150      * ael_yylex_init()
03151      */
03152     return 0;
03153 }
03154 
03155 /* ael_yylex_destroy is for both reentrant and non-reentrant scanners. */
03156 int ael_yylex_destroy  (yyscan_t yyscanner)
03157 {
03158     struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
03159 
03160     /* Pop the buffer stack, destroying each element. */
03161    while(YY_CURRENT_BUFFER){
03162       ael_yy_delete_buffer(YY_CURRENT_BUFFER ,yyscanner );
03163       YY_CURRENT_BUFFER_LVALUE = NULL;
03164       ael_yypop_buffer_state(yyscanner);
03165    }
03166 
03167    /* Destroy the stack itself. */
03168    ael_yyfree(yyg->yy_buffer_stack ,yyscanner);
03169    yyg->yy_buffer_stack = NULL;
03170 
03171     /* Destroy the start condition stack. */
03172         ael_yyfree(yyg->yy_start_stack ,yyscanner );
03173         yyg->yy_start_stack = NULL;
03174 
03175     /* Reset the globals. This is important in a non-reentrant scanner so the next time
03176      * ael_yylex() is called, initialization will occur. */
03177     yy_init_globals( yyscanner);
03178 
03179     /* Destroy the main struct (reentrant only). */
03180     ael_yyfree ( yyscanner , yyscanner );
03181     yyscanner = NULL;
03182     return 0;
03183 }
03184 
03185 /*
03186  * Internal utility routines.
03187  */
03188 
03189 #ifndef yytext_ptr
03190 static void yy_flex_strncpy (char* s1, yyconst char * s2, int n , yyscan_t yyscanner)
03191 {
03192    register int i;
03193    for ( i = 0; i < n; ++i )
03194       s1[i] = s2[i];
03195 }
03196 #endif
03197 
03198 #ifdef YY_NEED_STRLEN
03199 static int yy_flex_strlen (yyconst char * s , yyscan_t yyscanner)
03200 {
03201    register int n;
03202    for ( n = 0; s[n]; ++n )
03203       ;
03204 
03205    return n;
03206 }
03207 #endif
03208 
03209 void *ael_yyalloc (yy_size_t  size , yyscan_t yyscanner)
03210 {
03211    return (void *) malloc( size );
03212 }
03213 
03214 void *ael_yyrealloc  (void * ptr, yy_size_t  size , yyscan_t yyscanner)
03215 {
03216    /* The cast to (char *) in the following accommodates both
03217     * implementations that use char* generic pointers, and those
03218     * that use void* generic pointers.  It works with the latter
03219     * because both ANSI C and C++ allow castless assignment from
03220     * any pointer type to void*, and deal with argument conversions
03221     * as though doing an assignment.
03222     */
03223    return (void *) realloc( (char *) ptr, size );
03224 }
03225 
03226 #define YYTABLES_NAME "yytables"
03227 
03228 #line 656 "ael.flex"
03229 
03230 
03231 
03232 static void pbcpush(char x)
03233 {
03234    pbcstack[pbcpos++] = x;
03235 }
03236 
03237 void ael_yyfree(void *ptr, yyscan_t yyscanner)
03238 {
03239    if (ptr)
03240       free( (char*) ptr );
03241 }
03242 
03243 static int pbcpop(char x)
03244 {
03245    if (   ( x == ')' && pbcstack[pbcpos-1] == '(' )
03246       || ( x == ']' && pbcstack[pbcpos-1] == '[' )
03247       || ( x == '}' && pbcstack[pbcpos-1] == '{' )) {
03248       pbcpos--;
03249       return 0;
03250    }
03251    return 1; /* error */
03252 }
03253 
03254 static void pbcpush2(char x)
03255 {
03256    pbcstack2[pbcpos2++] = x;
03257 }
03258 
03259 static int pbcpop2(char x)
03260 {
03261    if (   ( x == ')' && pbcstack2[pbcpos2-1] == '(' )
03262       || ( x == ']' && pbcstack2[pbcpos2-1] == '[' )
03263       || ( x == '}' && pbcstack2[pbcpos2-1] == '{' )) {
03264       pbcpos2--;
03265       return 0;
03266    }
03267    return 1; /* error */
03268 }
03269 
03270 static void pbcpush3(char x)
03271 {
03272    pbcstack3[pbcpos3++] = x;
03273 }
03274 
03275 static int pbcpop3(char x)
03276 {
03277    if (   ( x == ')' && pbcstack3[pbcpos3-1] == '(' )
03278       || ( x == ']' && pbcstack3[pbcpos3-1] == '[' )
03279       || ( x == '}' && pbcstack3[pbcpos3-1] == '{' )) {
03280       pbcpos3--;
03281       return 0;
03282    }
03283    return 1; /* error */
03284 }
03285 
03286 static int c_prevword(void)
03287 {
03288    char *c = prev_word;
03289    if (c == NULL)
03290       return 0;
03291    while ( *c ) {
03292       switch (*c) {
03293       case '{':
03294       case '[':
03295       case '(':
03296          pbcpush(*c);
03297          break;
03298       case '}':
03299       case ']':
03300       case ')':
03301          if (pbcpop(*c))
03302             return 1;
03303          break;
03304       }
03305       c++;
03306    }
03307    return 0;
03308 }
03309 
03310 
03311 /*
03312  * The following three functions, reset_*, are used in the bison
03313  * code to switch context. As a consequence, we need to
03314  * declare them global and add a prototype so that the
03315  * compiler does not complain.
03316  *
03317  * NOTE: yyg is declared because it is used in the BEGIN macros,
03318  * though that should be hidden as the macro changes
03319  * depending on the flex options that we use - in particular,
03320  * %reentrant changes the way the macro is declared;
03321  * without %reentrant, BEGIN uses yystart instead of yyg
03322  */
03323 
03324 void reset_parencount(yyscan_t yyscanner );
03325 void reset_parencount(yyscan_t yyscanner )
03326 {
03327    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
03328    parencount = 0;
03329    pbcpos = 0;
03330    pbcpush('(');  /* push '(' so the last pcbpop (parencount= -1) will succeed */
03331    c_prevword();
03332    BEGIN(paren);
03333 }
03334 
03335 void reset_semicount(yyscan_t yyscanner );
03336 void reset_semicount(yyscan_t yyscanner )
03337 {
03338    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
03339    pbcpos = 0;
03340    BEGIN(semic);
03341 }
03342 
03343 void reset_argcount(yyscan_t yyscanner );
03344 void reset_argcount(yyscan_t yyscanner )
03345 {
03346    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
03347    parencount = 0;
03348    pbcpos = 0;
03349    pbcpush('(');  /* push '(' so the last pcbpop (parencount= -1) will succeed */
03350    c_prevword();
03351    BEGIN(argg);
03352 }
03353 
03354 /* used elsewhere, but some local vars */
03355 struct pval *ael2_parse(char *filename, int *errors)
03356 {
03357    struct pval *pvalue;
03358    struct parse_io *io;
03359    char *buffer;
03360    struct stat stats;
03361    FILE *fin;
03362 
03363    /* extern int ael_yydebug; */
03364 
03365    io = calloc(sizeof(struct parse_io),1);
03366    /* reset the global counters */
03367    prev_word = 0;
03368    my_lineno = 1;
03369    include_stack_index=0;
03370    my_col = 0;
03371    /* ael_yydebug = 1; */
03372    ael_yylex_init(&io->scanner);
03373    fin = fopen(filename,"r");
03374    if ( !fin ) {
03375       ast_log(LOG_ERROR,"File %s could not be opened\n", filename);
03376       *errors = 1;
03377       return 0;
03378    }
03379    if (my_file)
03380       free(my_file);
03381    my_file = strdup(filename);
03382    if (stat(filename, &stats)) {
03383       ast_log(LOG_WARNING, "failed to populate stats from file '%s'\n", filename);
03384    }
03385    buffer = (char*)malloc(stats.st_size+2);
03386    if (fread(buffer, 1, stats.st_size, fin) != stats.st_size) {
03387       ast_log(LOG_ERROR, "fread() failed: %s\n", strerror(errno));
03388    }        
03389    buffer[stats.st_size]=0;
03390    fclose(fin);
03391 
03392    ael_yy_scan_string (buffer ,io->scanner);
03393    ael_yyset_lineno(1 , io->scanner);
03394 
03395    /* ael_yyset_in (fin , io->scanner);   OLD WAY */
03396 
03397    ael_yyparse(io);
03398 
03399 
03400    pvalue = io->pval;
03401    *errors = io->syntax_error_count;
03402 
03403    ael_yylex_destroy(io->scanner);
03404    free(buffer);
03405    free(io);
03406 
03407    return pvalue;
03408 }
03409 
03410 static void setup_filestack(char *fnamebuf2, int fnamebuf_siz, glob_t *globbuf, int globpos, yyscan_t yyscanner, int create)
03411 {
03412    struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
03413    int error, i;
03414    FILE *in1;
03415    char fnamebuf[2048];
03416 
03417    if (globbuf && globbuf->gl_pathv && globbuf->gl_pathc > 0)
03418 #if defined(STANDALONE) || defined(LOW_MEMORY) || defined(STANDALONE_AEL)
03419          strncpy(fnamebuf, globbuf->gl_pathv[globpos], fnamebuf_siz);
03420 #else
03421          ast_copy_string(fnamebuf, globbuf->gl_pathv[globpos], fnamebuf_siz);
03422 #endif
03423    else {
03424       ast_log(LOG_ERROR,"Include file name not present!\n");
03425       return;
03426    }
03427    for (i=0; i<include_stack_index; i++) {
03428       if ( !strcmp(fnamebuf,include_stack[i].fname )) {
03429          ast_log(LOG_ERROR,"File=%s, line=%d, column=%d: Nice Try!!! But %s has already been included (perhaps by another file), and would cause an infinite loop of file inclusions!!! Include directive ignored\n",
03430             my_file, my_lineno, my_col, fnamebuf);
03431          break;
03432       }
03433    }
03434    error = 1;
03435    if (i == include_stack_index)
03436       error = 0;  /* we can use this file */
03437    if ( !error ) {   /* valid file name */
03438       /* relative vs. absolute */
03439       if (fnamebuf[0] != '/')
03440          snprintf(fnamebuf2, fnamebuf_siz, "%s/%s", ast_config_AST_CONFIG_DIR, fnamebuf);
03441       else
03442 #if defined(STANDALONE) || defined(LOW_MEMORY) || defined(STANDALONE_AEL)
03443          strncpy(fnamebuf2, fnamebuf, fnamebuf_siz);
03444 #else
03445          ast_copy_string(fnamebuf2, fnamebuf, fnamebuf_siz);
03446 #endif
03447       in1 = fopen( fnamebuf2, "r" );
03448 
03449       if ( ! in1 ) {
03450          ast_log(LOG_ERROR,"File=%s, line=%d, column=%d: Couldn't find the include file: %s; ignoring the Include directive!\n", my_file, my_lineno, my_col, fnamebuf2);
03451       } else {
03452          char *buffer;
03453          struct stat stats;
03454          if (stat(fnamebuf2, &stats)) {
03455             ast_log(LOG_WARNING, "Failed to populate stats from file '%s'\n", fnamebuf2);
03456          }
03457          buffer = (char*)malloc(stats.st_size+1);
03458          if (fread(buffer, 1, stats.st_size, in1) != stats.st_size) {
03459             ast_log(LOG_ERROR, "fread() failed: %s\n", strerror(errno));
03460          }        
03461          buffer[stats.st_size] = 0;
03462          ast_debug(1, "  --Read in included file %s, %d chars\n",fnamebuf2, (int)stats.st_size);
03463          fclose(in1);
03464          if (include_stack[include_stack_index].fname) {
03465                free(include_stack[include_stack_index].fname);
03466             include_stack[include_stack_index].fname = 0;
03467          }
03468          include_stack[include_stack_index].fname = strdup(S_OR(my_file, "<none>"));
03469          include_stack[include_stack_index].lineno = my_lineno;
03470          include_stack[include_stack_index].colno = my_col+yyleng;
03471          if (my_file)
03472             free(my_file);
03473          my_file = strdup(fnamebuf2);
03474          if (create)
03475             include_stack[include_stack_index].globbuf = *globbuf;
03476 
03477          include_stack[include_stack_index].globbuf_pos = 0;
03478 
03479          include_stack[include_stack_index].bufstate = YY_CURRENT_BUFFER;
03480          if (create)
03481             include_stack_index++;
03482          ael_yy_switch_to_buffer(ael_yy_scan_string (buffer ,yyscanner),yyscanner);
03483          free(buffer);
03484          my_lineno = 1;
03485          my_col = 1;
03486          BEGIN(INITIAL);
03487       }
03488    }
03489 }
03490 

Generated on Thu Apr 16 06:27:06 2015 for Asterisk - The Open Source Telephony Project by  doxygen 1.5.6