"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "sbr/icalendar.c" between
nmh-1.7.1-RC3.tar.gz and nmh-1.7.1.tar.gz

About: nmh (new MH) is an electronic mail handling system.

icalendar.c  (nmh-1.7.1-RC3):icalendar.c  (nmh-1.7.1)
skipping to change at line 30 skipping to change at line 30
#define yyout icalout #define yyout icalout
#define yyrestart icalrestart #define yyrestart icalrestart
#define yytext icaltext #define yytext icaltext
#define yywrap icalwrap #define yywrap icalwrap
#define yyalloc icalalloc #define yyalloc icalalloc
#define yyrealloc icalrealloc #define yyrealloc icalrealloc
#define yyfree icalfree #define yyfree icalfree
#define FLEX_SCANNER #define FLEX_SCANNER
#define YY_FLEX_MAJOR_VERSION 2 #define YY_FLEX_MAJOR_VERSION 2
#define YY_FLEX_MINOR_VERSION 6 #define YY_FLEX_MINOR_VERSION 5
#define YY_FLEX_SUBMINOR_VERSION 0 #define YY_FLEX_SUBMINOR_VERSION 35
#if YY_FLEX_SUBMINOR_VERSION > 0 #if YY_FLEX_SUBMINOR_VERSION > 0
#define FLEX_BETA #define FLEX_BETA
#endif #endif
/* First, we deal with platform-specific or compiler-specific issues. */ /* First, we deal with platform-specific or compiler-specific issues. */
/* begin standard C headers. */ /* begin standard C headers. */
#include <stdio.h> #include <stdio.h>
#include <string.h> #include <string.h>
#include <errno.h> #include <errno.h>
skipping to change at line 69 skipping to change at line 69
#define __STDC_LIMIT_MACROS 1 #define __STDC_LIMIT_MACROS 1
#endif #endif
#include <inttypes.h> #include <inttypes.h>
typedef int8_t flex_int8_t; typedef int8_t flex_int8_t;
typedef uint8_t flex_uint8_t; typedef uint8_t flex_uint8_t;
typedef int16_t flex_int16_t; typedef int16_t flex_int16_t;
typedef uint16_t flex_uint16_t; typedef uint16_t flex_uint16_t;
typedef int32_t flex_int32_t; typedef int32_t flex_int32_t;
typedef uint32_t flex_uint32_t; typedef uint32_t flex_uint32_t;
typedef uint64_t flex_uint64_t;
#else #else
typedef signed char flex_int8_t; typedef signed char flex_int8_t;
typedef short int flex_int16_t; typedef short int flex_int16_t;
typedef int flex_int32_t; typedef int flex_int32_t;
typedef unsigned char flex_uint8_t; typedef unsigned char flex_uint8_t;
typedef unsigned short int flex_uint16_t; typedef unsigned short int flex_uint16_t;
typedef unsigned int flex_uint32_t; typedef unsigned int flex_uint32_t;
#endif /* ! C99 */
/* Limits of integral types. */ /* Limits of integral types. */
#ifndef INT8_MIN #ifndef INT8_MIN
#define INT8_MIN (-128) #define INT8_MIN (-128)
#endif #endif
#ifndef INT16_MIN #ifndef INT16_MIN
#define INT16_MIN (-32767-1) #define INT16_MIN (-32767-1)
#endif #endif
#ifndef INT32_MIN #ifndef INT32_MIN
#define INT32_MIN (-2147483647-1) #define INT32_MIN (-2147483647-1)
skipping to change at line 106 skipping to change at line 108
#ifndef UINT8_MAX #ifndef UINT8_MAX
#define UINT8_MAX (255U) #define UINT8_MAX (255U)
#endif #endif
#ifndef UINT16_MAX #ifndef UINT16_MAX
#define UINT16_MAX (65535U) #define UINT16_MAX (65535U)
#endif #endif
#ifndef UINT32_MAX #ifndef UINT32_MAX
#define UINT32_MAX (4294967295U) #define UINT32_MAX (4294967295U)
#endif #endif
#endif /* ! C99 */
#endif /* ! FLEXINT_H */ #endif /* ! FLEXINT_H */
#ifdef __cplusplus #ifdef __cplusplus
/* The "const" storage-class-modifier is valid. */ /* The "const" storage-class-modifier is valid. */
#define YY_USE_CONST #define YY_USE_CONST
#else /* ! __cplusplus */ #else /* ! __cplusplus */
/* C99 requires __STDC__ to be defined as 1. */ /* C99 requires __STDC__ to be defined as 1. */
skipping to change at line 164 skipping to change at line 164
/* Action number for EOF rule of a given start state. */ /* Action number for EOF rule of a given start state. */
#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1) #define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
/* Special action meaning "start processing a new file". */ /* Special action meaning "start processing a new file". */
#define YY_NEW_FILE icalrestart(icalin ) #define YY_NEW_FILE icalrestart(icalin )
#define YY_END_OF_BUFFER_CHAR 0 #define YY_END_OF_BUFFER_CHAR 0
/* Size of default input buffer. */ /* Size of default input buffer. */
#ifndef YY_BUF_SIZE #ifndef YY_BUF_SIZE
#ifdef __ia64__
/* On IA-64, the buffer size is 16k, not 8k.
* Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
* Ditto for the __ia64__ case accordingly.
*/
#define YY_BUF_SIZE 32768
#else
#define YY_BUF_SIZE 16384 #define YY_BUF_SIZE 16384
#endif /* __ia64__ */
#endif #endif
/* The state buf must be large enough to hold one state per character in the mai n buffer. /* The state buf must be large enough to hold one state per character in the mai n buffer.
*/ */
#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type)) #define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type))
#ifndef YY_TYPEDEF_YY_BUFFER_STATE #ifndef YY_TYPEDEF_YY_BUFFER_STATE
#define YY_TYPEDEF_YY_BUFFER_STATE #define YY_TYPEDEF_YY_BUFFER_STATE
typedef struct yy_buffer_state *YY_BUFFER_STATE; typedef struct yy_buffer_state *YY_BUFFER_STATE;
#endif #endif
skipping to change at line 198 skipping to change at line 190
extern yy_size_t icalleng; extern yy_size_t icalleng;
extern FILE *icalin, *icalout; extern FILE *icalin, *icalout;
#define EOB_ACT_CONTINUE_SCAN 0 #define EOB_ACT_CONTINUE_SCAN 0
#define EOB_ACT_END_OF_FILE 1 #define EOB_ACT_END_OF_FILE 1
#define EOB_ACT_LAST_MATCH 2 #define EOB_ACT_LAST_MATCH 2
#define YY_LESS_LINENO(n) #define YY_LESS_LINENO(n)
#define YY_LINENO_REWIND_TO(ptr)
/* Return all but the first "n" matched characters back to the input stream. */ /* Return all but the first "n" matched characters back to the input stream. */
#define yyless(n) \ #define yyless(n) \
do \ do \
{ \ { \
/* Undo effects of setting up icaltext. */ \ /* Undo effects of setting up icaltext. */ \
int yyless_macro_arg = (n); \ int yyless_macro_arg = (n); \
YY_LESS_LINENO(yyless_macro_arg);\ YY_LESS_LINENO(yyless_macro_arg);\
*yy_cp = (yy_hold_char); \ *yy_cp = (yy_hold_char); \
YY_RESTORE_YY_MORE_OFFSET \ YY_RESTORE_YY_MORE_OFFSET \
skipping to change at line 364 skipping to change at line 355
YY_CURRENT_BUFFER_LVALUE = \ YY_CURRENT_BUFFER_LVALUE = \
ical_create_buffer(icalin,YY_BUF_SIZE ); \ ical_create_buffer(icalin,YY_BUF_SIZE ); \
} \ } \
YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \ YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
} }
#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol) #define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol)
/* Begin user sect3 */ /* Begin user sect3 */
#define icalwrap() (/*CONSTCOND*/1) #define icalwrap(n) 1
#define YY_SKIP_YYWRAP #define YY_SKIP_YYWRAP
typedef unsigned char YY_CHAR; typedef unsigned char YY_CHAR;
FILE *icalin = (FILE *) 0, *icalout = (FILE *) 0; FILE *icalin = (FILE *) 0, *icalout = (FILE *) 0;
typedef int yy_state_type; typedef int yy_state_type;
extern int icallineno; extern int icallineno;
int icallineno = 1; int icallineno = 1;
extern char *icaltext; extern char *icaltext;
#ifdef yytext_ptr
#undef yytext_ptr
#endif
#define yytext_ptr icaltext #define yytext_ptr icaltext
static yy_state_type yy_get_previous_state (void ); static yy_state_type yy_get_previous_state (void );
static yy_state_type yy_try_NUL_trans (yy_state_type current_state ); static yy_state_type yy_try_NUL_trans (yy_state_type current_state );
static int yy_get_next_buffer (void ); static int yy_get_next_buffer (void );
#if defined(__GNUC__) && __GNUC__ >= 3
__attribute__((__noreturn__))
#endif
static void yy_fatal_error (yyconst char msg[] ); static void yy_fatal_error (yyconst char msg[] );
/* Done after the current pattern has been matched and before the /* Done after the current pattern has been matched and before the
* corresponding action - sets up icaltext. * corresponding action - sets up icaltext.
*/ */
#define YY_DO_BEFORE_ACTION \ #define YY_DO_BEFORE_ACTION \
(yytext_ptr) = yy_bp; \ (yytext_ptr) = yy_bp; \
icalleng = (size_t) (yy_cp - yy_bp); \ icalleng = (yy_size_t) (yy_cp - yy_bp); \
(yy_hold_char) = *yy_cp; \ (yy_hold_char) = *yy_cp; \
*yy_cp = '\0'; \ *yy_cp = '\0'; \
(yy_c_buf_p) = yy_cp; (yy_c_buf_p) = yy_cp;
#define YY_NUM_RULES 17 #define YY_NUM_RULES 17
#define YY_END_OF_BUFFER 18 #define YY_END_OF_BUFFER 18
/* This struct is not used in this scanner, /* This struct is not used in this scanner,
but its presence is necessary. */ but its presence is necessary. */
struct yy_trans_info struct yy_trans_info
{ {
skipping to change at line 428 skipping to change at line 413
12, 0, 0, 0, 11, 0, 0, 0, 12, 0, 12, 0, 0, 0, 11, 0, 0, 0, 12, 0,
12, 0, 3, 3, 5, 0, 6, 0, 9, 9, 12, 0, 3, 3, 5, 0, 6, 0, 9, 9,
11, 0, 0, 0, 12, 2, 3, 5, 6, 8, 11, 0, 0, 0, 12, 2, 3, 5, 6, 8,
9, 11, 0, 11, 0, 0, 12, 3, 5, 6, 9, 11, 0, 11, 0, 0, 12, 3, 5, 6,
9, 11, 0, 0, 12, 3, 3, 5, 6, 9, 9, 11, 0, 0, 12, 3, 3, 5, 6, 9,
9, 11, 0, 0, 12, 5, 11, 0, 0, 5, 9, 11, 0, 0, 12, 5, 11, 0, 0, 5,
11, 0, 0, 0 11, 0, 0, 0
} ; } ;
static yyconst YY_CHAR yy_ec[256] = static yyconst flex_int32_t yy_ec[256] =
{ 0, { 0,
1, 1, 1, 1, 1, 1, 1, 1, 2, 3, 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 5, 6, 7, 6, 6, 6, 6, 6, 6, 1, 5, 6, 7, 6, 6, 6, 6, 6, 6,
6, 6, 6, 8, 9, 6, 6, 10, 10, 10, 6, 6, 6, 8, 9, 6, 6, 10, 10, 10,
10, 10, 10, 10, 10, 10, 10, 11, 12, 6, 10, 10, 10, 10, 10, 10, 10, 11, 12, 6,
13, 6, 6, 6, 14, 14, 14, 14, 14, 14, 13, 6, 6, 6, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
14, 14, 14, 14, 14, 14, 14, 15, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 14, 14,
skipping to change at line 460 skipping to change at line 445
16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
16, 16, 16, 16, 16, 16, 16, 16, 1, 1, 16, 16, 16, 16, 16, 16, 16, 16, 1, 1,
1, 1, 1, 1, 1 1, 1, 1, 1, 1
} ; } ;
static yyconst YY_CHAR yy_meta[17] = static yyconst flex_int32_t yy_meta[17] =
{ 0, { 0,
1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2 2, 2, 2, 2, 2, 2
} ; } ;
static yyconst flex_uint16_t yy_base[131] = static yyconst flex_int16_t yy_base[131] =
{ 0, { 0,
0, 13, 26, 0, 38, 54, 2, 4, 68, 0, 0, 13, 26, 0, 38, 54, 2, 4, 68, 0,
8, 17, 83, 0, 0, 0, 136, 406, 9, 132, 8, 17, 83, 0, 0, 0, 136, 406, 9, 132,
97, 125, 406, 406, 406, 406, 110, 125, 130, 109, 97, 125, 406, 406, 406, 406, 110, 125, 130, 109,
15, 121, 128, 114, 406, 142, 157, 119, 160, 105, 15, 121, 128, 114, 406, 142, 157, 119, 160, 105,
21, 117, 175, 116, 0, 178, 191, 28, 115, 101, 21, 117, 175, 116, 0, 178, 191, 28, 115, 101,
205, 0, 113, 99, 32, 107, 220, 106, 0, 223, 205, 0, 113, 99, 32, 107, 220, 106, 0, 223,
0, 0, 105, 89, 237, 251, 266, 101, 406, 87, 0, 0, 105, 89, 237, 251, 266, 101, 406, 87,
86, 269, 275, 281, 294, 65, 64, 308, 314, 320, 86, 269, 275, 281, 294, 65, 64, 308, 314, 320,
0, 63, 333, 60, 59, 0, 340, 58, 57, 0, 0, 63, 333, 60, 59, 0, 340, 58, 57, 0,
skipping to change at line 502 skipping to change at line 487
36, 37, 124, 124, 124, 128, 124, 124, 124, 124, 36, 37, 124, 124, 124, 128, 124, 124, 124, 124,
36, 124, 46, 46, 129, 124, 47, 124, 60, 60, 36, 124, 46, 46, 129, 124, 47, 124, 60, 60,
65, 124, 130, 66, 36, 72, 46, 75, 47, 78, 65, 124, 130, 66, 36, 72, 46, 75, 47, 78,
60, 65, 130, 124, 124, 66, 36, 124, 75, 47, 60, 65, 130, 124, 124, 66, 36, 124, 75, 47,
124, 65, 93, 66, 36, 73, 98, 75, 47, 79, 124, 65, 93, 66, 36, 73, 98, 75, 47, 79,
101, 65, 93, 66, 36, 75, 65, 93, 66, 75, 101, 65, 93, 66, 36, 75, 65, 93, 66, 75,
65, 93, 93, 0, 124, 124, 124, 124, 124, 124 65, 93, 93, 0, 124, 124, 124, 124, 124, 124
} ; } ;
static yyconst flex_uint16_t yy_nxt[423] = static yyconst flex_int16_t yy_nxt[423] =
{ 0, { 0,
124, 93, 19, 20, 31, 32, 31, 32, 21, 21, 124, 93, 19, 20, 31, 32, 31, 32, 21, 21,
23, 41, 42, 21, 22, 19, 20, 55, 56, 23, 23, 41, 42, 21, 22, 19, 20, 55, 56, 23,
35, 21, 21, 41, 42, 75, 21, 22, 23, 35, 35, 21, 21, 41, 42, 75, 21, 22, 23, 35,
48, 49, 66, 24, 55, 56, 25, 26, 18, 47, 48, 49, 66, 24, 55, 56, 25, 26, 18, 47,
28, 29, 123, 123, 121, 120, 119, 122, 121, 120, 28, 29, 123, 123, 121, 120, 119, 122, 121, 120,
115, 119, 118, 30, 18, 117, 28, 29, 109, 116, 115, 119, 118, 30, 18, 117, 28, 29, 109, 116,
115, 114, 113, 112, 109, 108, 105, 104, 103, 30, 115, 114, 113, 112, 109, 108, 105, 104, 103, 30,
23, 102, 100, 99, 97, 96, 33, 33, 92, 89, 23, 102, 100, 99, 97, 96, 33, 33, 92, 89,
88, 33, 34, 18, 36, 37, 38, 36, 36, 39, 88, 33, 34, 18, 36, 37, 38, 36, 36, 39,
skipping to change at line 663 skipping to change at line 648
/* /*
* Core rules (definitions) from RFC 5234 Appendix B.1. * Core rules (definitions) from RFC 5234 Appendix B.1.
*/ */
/* Variance from RFC 5234: the {CR} is required in /* Variance from RFC 5234: the {CR} is required in
CRLF, but it is optional below to support Unix CRLF, but it is optional below to support Unix
filesystem convention. */ filesystem convention. */
/* /*
* Our definitions. * Our definitions.
*/ */
#line 664 "sbr/icalendar.c" #line 649 "sbr/icalendar.c"
#define INITIAL 0 #define INITIAL 0
#define s_name 1 #define s_name 1
#define s_colon 2 #define s_colon 2
#define s_value 3 #define s_value 3
#define s_semicolon 4 #define s_semicolon 4
#define s_param_name 5 #define s_param_name 5
#define s_equal 6 #define s_equal 6
#define s_comma 7 #define s_comma 7
skipping to change at line 703 skipping to change at line 688
int icalget_debug (void ); int icalget_debug (void );
void icalset_debug (int debug_flag ); void icalset_debug (int debug_flag );
YY_EXTRA_TYPE icalget_extra (void ); YY_EXTRA_TYPE icalget_extra (void );
void icalset_extra (YY_EXTRA_TYPE user_defined ); void icalset_extra (YY_EXTRA_TYPE user_defined );
FILE *icalget_in (void ); FILE *icalget_in (void );
void icalset_in (FILE * _in_str ); void icalset_in (FILE * in_str );
FILE *icalget_out (void ); FILE *icalget_out (void );
void icalset_out (FILE * _out_str ); void icalset_out (FILE * out_str );
yy_size_t icalget_leng (void ); yy_size_t icalget_leng (void );
char *icalget_text (void ); char *icalget_text (void );
int icalget_lineno (void ); int icalget_lineno (void );
void icalset_lineno (int _line_number ); void icalset_lineno (int line_number );
/* Macros after this point can all be overridden by user definitions in /* Macros after this point can all be overridden by user definitions in
* section 1. * section 1.
*/ */
#ifndef YY_SKIP_YYWRAP #ifndef YY_SKIP_YYWRAP
#ifdef __cplusplus #ifdef __cplusplus
extern "C" int icalwrap (void ); extern "C" int icalwrap (void );
#else #else
extern int icalwrap (void ); extern int icalwrap (void );
#endif #endif
#endif #endif
#ifndef YY_NO_UNPUT
static void yyunput (int c,char *buf_ptr ); static void yyunput (int c,char *buf_ptr );
#endif
#ifndef yytext_ptr #ifndef yytext_ptr
static void yy_flex_strncpy (char *,yyconst char *,int ); static void yy_flex_strncpy (char *,yyconst char *,int );
#endif #endif
#ifdef YY_NEED_STRLEN #ifdef YY_NEED_STRLEN
static int yy_flex_strlen (yyconst char * ); static int yy_flex_strlen (yyconst char * );
#endif #endif
#ifndef YY_NO_INPUT #ifndef YY_NO_INPUT
#ifdef __cplusplus #ifdef __cplusplus
static int yyinput (void ); static int yyinput (void );
#else #else
static int input (void ); static int input (void );
#endif #endif
#endif #endif
/* Amount of stuff to slurp up with each read. */ /* Amount of stuff to slurp up with each read. */
#ifndef YY_READ_BUF_SIZE #ifndef YY_READ_BUF_SIZE
#ifdef __ia64__
/* On IA-64, the buffer size is 16k, not 8k */
#define YY_READ_BUF_SIZE 16384
#else
#define YY_READ_BUF_SIZE 8192 #define YY_READ_BUF_SIZE 8192
#endif /* __ia64__ */
#endif #endif
/* Copy whatever the last rule matched to the standard output. */ /* Copy whatever the last rule matched to the standard output. */
#ifndef ECHO #ifndef ECHO
/* This used to be an fputs(), but since the string might contain NUL's, /* This used to be an fputs(), but since the string might contain NUL's,
* we now use fwrite(). * we now use fwrite().
*/ */
#define ECHO do { if (fwrite( icaltext, icalleng, 1, icalout )) {} } while (0) #define ECHO fwrite( icaltext, icalleng, 1, icalout )
#endif #endif
/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, /* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
* is returned in "result". * is returned in "result".
*/ */
#ifndef YY_INPUT #ifndef YY_INPUT
#define YY_INPUT(buf,result,max_size) \ #define YY_INPUT(buf,result,max_size) \
if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \
{ \ { \
int c = '*'; \ int c = '*'; \
size_t n; \ yy_size_t n; \
for ( n = 0; n < max_size && \ for ( n = 0; n < max_size && \
(c = getc( icalin )) != EOF && c != '\n'; ++n ) \ (c = getc( icalin )) != EOF && c != '\n'; ++n ) \
buf[n] = (char) c; \ buf[n] = (char) c; \
if ( c == '\n' ) \ if ( c == '\n' ) \
buf[n++] = (char) c; \ buf[n++] = (char) c; \
if ( c == EOF && ferror( icalin ) ) \ if ( c == EOF && ferror( icalin ) ) \
YY_FATAL_ERROR( "input in flex scanner failed" ); \ YY_FATAL_ERROR( "input in flex scanner failed" ); \
result = n; \ result = n; \
} \ } \
else \ else \
skipping to change at line 847 skipping to change at line 823
/* Code executed at the beginning of each rule, after icaltext and icalleng /* Code executed at the beginning of each rule, after icaltext and icalleng
* have been set up. * have been set up.
*/ */
#ifndef YY_USER_ACTION #ifndef YY_USER_ACTION
#define YY_USER_ACTION #define YY_USER_ACTION
#endif #endif
/* Code executed at the end of each rule. */ /* Code executed at the end of each rule. */
#ifndef YY_BREAK #ifndef YY_BREAK
#define YY_BREAK /*LINTED*/break; #define YY_BREAK break;
#endif #endif
#define YY_RULE_SETUP \ #define YY_RULE_SETUP \
YY_USER_ACTION YY_USER_ACTION
/** The main scanner function which does all the work. /** The main scanner function which does all the work.
*/ */
YY_DECL YY_DECL
{ {
yy_state_type yy_current_state; register yy_state_type yy_current_state;
char *yy_cp, *yy_bp; register char *yy_cp, *yy_bp;
int yy_act; register int yy_act;
#line 100 "sbr/icalendar.l"
#line 841 "sbr/icalendar.c"
if ( !(yy_init) ) if ( !(yy_init) )
{ {
(yy_init) = 1; (yy_init) = 1;
#ifdef YY_USER_INIT #ifdef YY_USER_INIT
YY_USER_INIT; YY_USER_INIT;
#endif #endif
if ( ! (yy_start) ) if ( ! (yy_start) )
skipping to change at line 887 skipping to change at line 867
if ( ! YY_CURRENT_BUFFER ) { if ( ! YY_CURRENT_BUFFER ) {
icalensure_buffer_stack (); icalensure_buffer_stack ();
YY_CURRENT_BUFFER_LVALUE = YY_CURRENT_BUFFER_LVALUE =
ical_create_buffer(icalin,YY_BUF_SIZE ); ical_create_buffer(icalin,YY_BUF_SIZE );
} }
ical_load_buffer_state( ); ical_load_buffer_state( );
} }
{ while ( 1 ) /* loops until end-of-file is reached */
#line 100 "sbr/icalendar.l"
#line 892 "sbr/icalendar.c"
while ( /*CONSTCOND*/1 ) /* loops until end-of-file is rea
ched */
{ {
yy_cp = (yy_c_buf_p); yy_cp = (yy_c_buf_p);
/* Support of icaltext. */ /* Support of icaltext. */
*yy_cp = (yy_hold_char); *yy_cp = (yy_hold_char);
/* yy_bp points to the position in yy_ch_buf of the start of /* yy_bp points to the position in yy_ch_buf of the start of
* the current run. * the current run.
*/ */
yy_bp = yy_cp; yy_bp = yy_cp;
yy_current_state = (yy_start); yy_current_state = (yy_start);
yy_match: yy_match:
do do
{ {
YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)] ; register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
if ( yy_accept[yy_current_state] ) if ( yy_accept[yy_current_state] )
{ {
(yy_last_accepting_state) = yy_current_state; (yy_last_accepting_state) = yy_current_state;
(yy_last_accepting_cpos) = yy_cp; (yy_last_accepting_cpos) = yy_cp;
} }
while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_cu rrent_state ) while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_cu rrent_state )
{ {
yy_current_state = (int) yy_def[yy_current_state] ; yy_current_state = (int) yy_def[yy_current_state] ;
if ( yy_current_state >= 125 ) if ( yy_current_state >= 125 )
yy_c = yy_meta[(unsigned int) yy_c]; yy_c = yy_meta[(unsigned int) yy_c];
skipping to change at line 1198 skipping to change at line 1173
start state to terminate on the next call. */ start state to terminate on the next call. */
BEGIN (INITIAL); BEGIN (INITIAL);
return ICAL_CRLF; return ICAL_CRLF;
} }
YY_BREAK YY_BREAK
case 17: case 17:
YY_RULE_SETUP YY_RULE_SETUP
#line 288 "sbr/icalendar.l" #line 288 "sbr/icalendar.l"
ECHO; ECHO;
YY_BREAK YY_BREAK
#line 1200 "sbr/icalendar.c" #line 1175 "sbr/icalendar.c"
case YY_END_OF_BUFFER: case YY_END_OF_BUFFER:
{ {
/* Amount of text matched not including the EOB char. */ /* Amount of text matched not including the EOB char. */
int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1; int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1;
/* Undo the effects of YY_DO_BEFORE_ACTION. */ /* Undo the effects of YY_DO_BEFORE_ACTION. */
*yy_cp = (yy_hold_char); *yy_cp = (yy_hold_char);
YY_RESTORE_YY_MORE_OFFSET YY_RESTORE_YY_MORE_OFFSET
skipping to change at line 1328 skipping to change at line 1303
goto yy_find_action; goto yy_find_action;
} }
break; break;
} }
default: default:
YY_FATAL_ERROR( YY_FATAL_ERROR(
"fatal flex scanner internal error--no action found" ); "fatal flex scanner internal error--no action found" );
} /* end of action switch */ } /* end of action switch */
} /* end of scanning one token */ } /* end of scanning one token */
} /* end of user's declarations */
} /* end of icallex */ } /* end of icallex */
/* yy_get_next_buffer - try to read in a new buffer /* yy_get_next_buffer - try to read in a new buffer
* *
* Returns a code representing an action: * Returns a code representing an action:
* EOB_ACT_LAST_MATCH - * EOB_ACT_LAST_MATCH -
* EOB_ACT_CONTINUE_SCAN - continue scanning from current position * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
* EOB_ACT_END_OF_FILE - end of file * EOB_ACT_END_OF_FILE - end of file
*/ */
static int yy_get_next_buffer (void) static int yy_get_next_buffer (void)
{ {
char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf; register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf;
char *source = (yytext_ptr); register char *source = (yytext_ptr);
yy_size_t number_to_move, i; register int number_to_move, i;
int ret_val; int ret_val;
if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1 ] ) if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1 ] )
YY_FATAL_ERROR( YY_FATAL_ERROR(
"fatal flex scanner internal error--end of buffer missed" ); "fatal flex scanner internal error--end of buffer missed" );
if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 ) if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 )
{ /* Don't try to fill the buffer, so this is an EOF. */ { /* Don't try to fill the buffer, so this is an EOF. */
if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 ) if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 )
{ {
skipping to change at line 1371 skipping to change at line 1345
/* We matched some text prior to the EOB, first /* We matched some text prior to the EOB, first
* process it. * process it.
*/ */
return EOB_ACT_LAST_MATCH; return EOB_ACT_LAST_MATCH;
} }
} }
/* Try to read more data. */ /* Try to read more data. */
/* First move last chars to start of buffer. */ /* First move last chars to start of buffer. */
number_to_move = (yy_size_t) ((yy_c_buf_p) - (yytext_ptr)) - 1; number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr)) - 1;
for ( i = 0; i < number_to_move; ++i ) for ( i = 0; i < number_to_move; ++i )
*(dest++) = *(source++); *(dest++) = *(source++);
if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING ) if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING )
/* don't do the read, it's not guaranteed to return an EOF, /* don't do the read, it's not guaranteed to return an EOF,
* just force an EOF * just force an EOF
*/ */
YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0; YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0;
else else
{ {
yy_size_t num_to_read = yy_size_t num_to_read =
YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1; YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
while ( num_to_read <= 0 ) while ( num_to_read <= 0 )
{ /* Not enough room in the buffer - grow it. */ { /* Not enough room in the buffer - grow it. */
/* just a shorter name for the current buffer */ /* just a shorter name for the current buffer */
YY_BUFFER_STATE b = YY_CURRENT_BUFFER_LVALUE; YY_BUFFER_STATE b = YY_CURRENT_BUFFER;
int yy_c_buf_p_offset = int yy_c_buf_p_offset =
(int) ((yy_c_buf_p) - b->yy_ch_buf); (int) ((yy_c_buf_p) - b->yy_ch_buf);
if ( b->yy_is_our_buffer ) if ( b->yy_is_our_buffer )
{ {
yy_size_t new_size = b->yy_buf_size * 2; yy_size_t new_size = b->yy_buf_size * 2;
if ( new_size <= 0 ) if ( new_size <= 0 )
b->yy_buf_size += b->yy_buf_size / 8; b->yy_buf_size += b->yy_buf_size / 8;
skipping to change at line 1429 skipping to change at line 1403
num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size -
number_to_move - 1; number_to_move - 1;
} }
if ( num_to_read > YY_READ_BUF_SIZE ) if ( num_to_read > YY_READ_BUF_SIZE )
num_to_read = YY_READ_BUF_SIZE; num_to_read = YY_READ_BUF_SIZE;
/* Read in more data. */ /* Read in more data. */
YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]), YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
(yy_n_chars), (size_t) num_to_read ); (yy_n_chars), num_to_read );
YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars);
} }
if ( (yy_n_chars) == 0 ) if ( (yy_n_chars) == 0 )
{ {
if ( number_to_move == YY_MORE_ADJ ) if ( number_to_move == YY_MORE_ADJ )
{ {
ret_val = EOB_ACT_END_OF_FILE; ret_val = EOB_ACT_END_OF_FILE;
icalrestart(icalin ); icalrestart(icalin );
skipping to change at line 1474 skipping to change at line 1448
(yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0]; (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0];
return ret_val; return ret_val;
} }
/* yy_get_previous_state - get the state just before the EOB char was reached */ /* yy_get_previous_state - get the state just before the EOB char was reached */
static yy_state_type yy_get_previous_state (void) static yy_state_type yy_get_previous_state (void)
{ {
yy_state_type yy_current_state; register yy_state_type yy_current_state;
char *yy_cp; register char *yy_cp;
yy_current_state = (yy_start); yy_current_state = (yy_start);
for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp ) for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp )
{ {
YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1); register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1) ;
if ( yy_accept[yy_current_state] ) if ( yy_accept[yy_current_state] )
{ {
(yy_last_accepting_state) = yy_current_state; (yy_last_accepting_state) = yy_current_state;
(yy_last_accepting_cpos) = yy_cp; (yy_last_accepting_cpos) = yy_cp;
} }
while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_st ate ) while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_st ate )
{ {
yy_current_state = (int) yy_def[yy_current_state]; yy_current_state = (int) yy_def[yy_current_state];
if ( yy_current_state >= 125 ) if ( yy_current_state >= 125 )
yy_c = yy_meta[(unsigned int) yy_c]; yy_c = yy_meta[(unsigned int) yy_c];
skipping to change at line 1506 skipping to change at line 1480
return yy_current_state; return yy_current_state;
} }
/* yy_try_NUL_trans - try to make a transition on the NUL character /* yy_try_NUL_trans - try to make a transition on the NUL character
* *
* synopsis * synopsis
* next_state = yy_try_NUL_trans( current_state ); * next_state = yy_try_NUL_trans( current_state );
*/ */
static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state ) static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state )
{ {
int yy_is_jam; register int yy_is_jam;
char *yy_cp = (yy_c_buf_p); register char *yy_cp = (yy_c_buf_p);
YY_CHAR yy_c = 1; register YY_CHAR yy_c = 1;
if ( yy_accept[yy_current_state] ) if ( yy_accept[yy_current_state] )
{ {
(yy_last_accepting_state) = yy_current_state; (yy_last_accepting_state) = yy_current_state;
(yy_last_accepting_cpos) = yy_cp; (yy_last_accepting_cpos) = yy_cp;
} }
while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
{ {
yy_current_state = (int) yy_def[yy_current_state]; yy_current_state = (int) yy_def[yy_current_state];
if ( yy_current_state >= 125 ) if ( yy_current_state >= 125 )
yy_c = yy_meta[(unsigned int) yy_c]; yy_c = yy_meta[(unsigned int) yy_c];
} }
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c ]; yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c ];
yy_is_jam = (yy_current_state == 124); yy_is_jam = (yy_current_state == 124);
return yy_is_jam ? 0 : yy_current_state; return yy_is_jam ? 0 : yy_current_state;
} }
#ifndef YY_NO_UNPUT static void yyunput (int c, register char * yy_bp )
static void yyunput (int c, char * yy_bp )
{ {
char *yy_cp; register char *yy_cp;
yy_cp = (yy_c_buf_p); yy_cp = (yy_c_buf_p);
/* undo effects of setting up icaltext */ /* undo effects of setting up icaltext */
*yy_cp = (yy_hold_char); *yy_cp = (yy_hold_char);
if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 ) if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 )
{ /* need to shift things up to make room */ { /* need to shift things up to make room */
/* +2 for EOB chars. */ /* +2 for EOB chars. */
yy_size_t number_to_move = (yy_n_chars) + 2; register yy_size_t number_to_move = (yy_n_chars) + 2;
char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[ register char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[
YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2 ]; YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2 ];
char *source = register char *source =
&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_mo ve]; &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_mo ve];
while ( source > YY_CURRENT_BUFFER_LVALUE->yy_ch_buf ) while ( source > YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
*--dest = *--source; *--dest = *--source;
yy_cp += (int) (dest - source); yy_cp += (int) (dest - source);
yy_bp += (int) (dest - source); yy_bp += (int) (dest - source);
YY_CURRENT_BUFFER_LVALUE->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars =
(yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_buf_size; (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_buf_size;
skipping to change at line 1566 skipping to change at line 1538
YY_FATAL_ERROR( "flex scanner push-back overflow" ); YY_FATAL_ERROR( "flex scanner push-back overflow" );
} }
*--yy_cp = (char) c; *--yy_cp = (char) c;
(yytext_ptr) = yy_bp; (yytext_ptr) = yy_bp;
(yy_hold_char) = *yy_cp; (yy_hold_char) = *yy_cp;
(yy_c_buf_p) = yy_cp; (yy_c_buf_p) = yy_cp;
} }
#endif
#ifndef YY_NO_INPUT #ifndef YY_NO_INPUT
#ifdef __cplusplus #ifdef __cplusplus
static int yyinput (void) static int yyinput (void)
#else #else
static int input (void) static int input (void)
#endif #endif
{ {
int c; int c;
skipping to change at line 1616 skipping to change at line 1586
*/ */
/* Reset buffer status. */ /* Reset buffer status. */
icalrestart(icalin ); icalrestart(icalin );
/*FALLTHROUGH*/ /*FALLTHROUGH*/
case EOB_ACT_END_OF_FILE: case EOB_ACT_END_OF_FILE:
{ {
if ( icalwrap( ) ) if ( icalwrap( ) )
return EOF; return 0;
if ( ! (yy_did_buffer_switch_on_eof) ) if ( ! (yy_did_buffer_switch_on_eof) )
YY_NEW_FILE; YY_NEW_FILE;
#ifdef __cplusplus #ifdef __cplusplus
return yyinput(); return yyinput();
#else #else
return input(); return input();
#endif #endif
} }
skipping to change at line 1717 skipping to change at line 1687
* @return the allocated buffer state. * @return the allocated buffer state.
*/ */
YY_BUFFER_STATE ical_create_buffer (FILE * file, int size ) YY_BUFFER_STATE ical_create_buffer (FILE * file, int size )
{ {
YY_BUFFER_STATE b; YY_BUFFER_STATE b;
b = (YY_BUFFER_STATE) icalalloc(sizeof( struct yy_buffer_state ) ); b = (YY_BUFFER_STATE) icalalloc(sizeof( struct yy_buffer_state ) );
if ( ! b ) if ( ! b )
YY_FATAL_ERROR( "out of dynamic memory in ical_create_buffer()" ) ; YY_FATAL_ERROR( "out of dynamic memory in ical_create_buffer()" ) ;
b->yy_buf_size = (yy_size_t)size; b->yy_buf_size = size;
/* yy_ch_buf has to be 2 characters longer than the size given because /* yy_ch_buf has to be 2 characters longer than the size given because
* we need to put in 2 end-of-buffer characters. * we need to put in 2 end-of-buffer characters.
*/ */
b->yy_ch_buf = (char *) icalalloc(b->yy_buf_size + 2 ); b->yy_ch_buf = (char *) icalalloc(b->yy_buf_size + 2 );
if ( ! b->yy_ch_buf ) if ( ! b->yy_ch_buf )
YY_FATAL_ERROR( "out of dynamic memory in ical_create_buffer()" ) ; YY_FATAL_ERROR( "out of dynamic memory in ical_create_buffer()" ) ;
b->yy_is_our_buffer = 1; b->yy_is_our_buffer = 1;
skipping to change at line 1872 skipping to change at line 1842
static void icalensure_buffer_stack (void) static void icalensure_buffer_stack (void)
{ {
yy_size_t num_to_alloc; yy_size_t num_to_alloc;
if (!(yy_buffer_stack)) { if (!(yy_buffer_stack)) {
/* First allocation is just for 2 elements, since we don't know i f this /* First allocation is just for 2 elements, since we don't know i f this
* scanner will even need a stack. We use 2 instead of 1 to avoid an * scanner will even need a stack. We use 2 instead of 1 to avoid an
* immediate realloc on the next call. * immediate realloc on the next call.
*/ */
num_to_alloc = 1; // After all that talk, this was set to 1 anywa ys... num_to_alloc = 1;
(yy_buffer_stack) = (struct yy_buffer_state**)icalalloc (yy_buffer_stack) = (struct yy_buffer_state**)icalalloc
(num_to_alloc * s izeof(struct yy_buffer_state*) (num_to_alloc * s izeof(struct yy_buffer_state*)
); );
if ( ! (yy_buffer_stack) ) if ( ! (yy_buffer_stack) )
YY_FATAL_ERROR( "out of dynamic memory in icalensure_buff er_stack()" ); YY_FATAL_ERROR( "out of dynamic memory in icalensure_buff er_stack()" );
memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buff er_state*)); memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buff er_state*));
(yy_buffer_stack_max) = num_to_alloc; (yy_buffer_stack_max) = num_to_alloc;
(yy_buffer_stack_top) = 0; (yy_buffer_stack_top) = 0;
return; return;
} }
if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){ if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){
/* Increase the buffer to prepare for a possible push. */ /* Increase the buffer to prepare for a possible push. */
yy_size_t grow_size = 8 /* arbitrary grow size */; int grow_size = 8 /* arbitrary grow size */;
num_to_alloc = (yy_buffer_stack_max) + grow_size; num_to_alloc = (yy_buffer_stack_max) + grow_size;
(yy_buffer_stack) = (struct yy_buffer_state**)icalrealloc (yy_buffer_stack) = (struct yy_buffer_state**)icalrealloc
((yy_buffer_stack ), ((yy_buffer_stack ),
num_to_alloc * si zeof(struct yy_buffer_state*) num_to_alloc * si zeof(struct yy_buffer_state*)
); );
if ( ! (yy_buffer_stack) ) if ( ! (yy_buffer_stack) )
YY_FATAL_ERROR( "out of dynamic memory in icalensure_buff er_stack()" ); YY_FATAL_ERROR( "out of dynamic memory in icalensure_buff er_stack()" );
/* zero only the new slots.*/ /* zero only the new slots.*/
skipping to change at line 1956 skipping to change at line 1926
* ical_scan_bytes() instead. * ical_scan_bytes() instead.
*/ */
YY_BUFFER_STATE ical_scan_string (yyconst char * yystr ) YY_BUFFER_STATE ical_scan_string (yyconst char * yystr )
{ {
return ical_scan_bytes(yystr,strlen(yystr) ); return ical_scan_bytes(yystr,strlen(yystr) );
} }
/** Setup the input buffer state to scan the given bytes. The next call to icall ex() will /** Setup the input buffer state to scan the given bytes. The next call to icall ex() will
* scan from a @e copy of @a bytes. * scan from a @e copy of @a bytes.
* @param yybytes the byte buffer to scan * @param bytes the byte buffer to scan
* @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes. * @param len the number of bytes in the buffer pointed to by @a bytes.
* *
* @return the newly allocated buffer state object. * @return the newly allocated buffer state object.
*/ */
YY_BUFFER_STATE ical_scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_le n ) YY_BUFFER_STATE ical_scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_le n )
{ {
YY_BUFFER_STATE b; YY_BUFFER_STATE b;
char *buf; char *buf;
yy_size_t n; yy_size_t n, i;
yy_size_t i;
/* Get memory for full buffer, including space for trailing EOB's. */ /* Get memory for full buffer, including space for trailing EOB's. */
n = _yybytes_len + 2; n = _yybytes_len + 2;
buf = (char *) icalalloc(n ); buf = (char *) icalalloc(n );
if ( ! buf ) if ( ! buf )
YY_FATAL_ERROR( "out of dynamic memory in ical_scan_bytes()" ); YY_FATAL_ERROR( "out of dynamic memory in ical_scan_bytes()" );
for ( i = 0; i < _yybytes_len; ++i ) for ( i = 0; i < _yybytes_len; ++i )
buf[i] = yybytes[i]; buf[i] = yybytes[i];
skipping to change at line 1997 skipping to change at line 1966
return b; return b;
} }
#ifndef YY_EXIT_FAILURE #ifndef YY_EXIT_FAILURE
#define YY_EXIT_FAILURE 2 #define YY_EXIT_FAILURE 2
#endif #endif
static void yy_fatal_error (yyconst char* msg ) static void yy_fatal_error (yyconst char* msg )
{ {
(void) fprintf( stderr, "%s\n", msg ); (void) fprintf( stderr, "%s\n", msg );
exit( YY_EXIT_FAILURE ); exit( YY_EXIT_FAILURE );
} }
/* Redefine yyless() so it works in section 3 code. */ /* Redefine yyless() so it works in section 3 code. */
#undef yyless #undef yyless
#define yyless(n) \ #define yyless(n) \
do \ do \
{ \ { \
/* Undo effects of setting up icaltext. */ \ /* Undo effects of setting up icaltext. */ \
skipping to change at line 2063 skipping to change at line 2032
/** Get the current token. /** Get the current token.
* *
*/ */
char *icalget_text (void) char *icalget_text (void)
{ {
return icaltext; return icaltext;
} }
/** Set the current line number. /** Set the current line number.
* @param _line_number line number * @param line_number
* *
*/ */
void icalset_lineno (int _line_number ) void icalset_lineno (int line_number )
{ {
icallineno = _line_number; icallineno = line_number;
} }
/** Set the input stream. This does not discard the current /** Set the input stream. This does not discard the current
* input buffer. * input buffer.
* @param _in_str A readable stream. * @param in_str A readable stream.
* *
* @see ical_switch_to_buffer * @see ical_switch_to_buffer
*/ */
void icalset_in (FILE * _in_str ) void icalset_in (FILE * in_str )
{ {
icalin = _in_str ; icalin = in_str ;
} }
void icalset_out (FILE * _out_str ) void icalset_out (FILE * out_str )
{ {
icalout = _out_str ; icalout = out_str ;
} }
int icalget_debug (void) int icalget_debug (void)
{ {
return ical_flex_debug; return ical_flex_debug;
} }
void icalset_debug (int _bdebug ) void icalset_debug (int bdebug )
{ {
ical_flex_debug = _bdebug ; ical_flex_debug = bdebug ;
} }
static int yy_init_globals (void) static int yy_init_globals (void)
{ {
/* Initialization is the same as for the non-reentrant scanner. /* Initialization is the same as for the non-reentrant scanner.
* This function is called from icallex_destroy(), so don't allocate here. * This function is called from icallex_destroy(), so don't allocate here.
*/ */
(yy_buffer_stack) = 0; (yy_buffer_stack) = 0;
(yy_buffer_stack_top) = 0; (yy_buffer_stack_top) = 0;
skipping to change at line 2155 skipping to change at line 2124
return 0; return 0;
} }
/* /*
* Internal utility routines. * Internal utility routines.
*/ */
#ifndef yytext_ptr #ifndef yytext_ptr
static void yy_flex_strncpy (char* s1, yyconst char * s2, int n ) static void yy_flex_strncpy (char* s1, yyconst char * s2, int n )
{ {
register int i;
int i;
for ( i = 0; i < n; ++i ) for ( i = 0; i < n; ++i )
s1[i] = s2[i]; s1[i] = s2[i];
} }
#endif #endif
#ifdef YY_NEED_STRLEN #ifdef YY_NEED_STRLEN
static int yy_flex_strlen (yyconst char * s ) static int yy_flex_strlen (yyconst char * s )
{ {
int n; register int n;
for ( n = 0; s[n]; ++n ) for ( n = 0; s[n]; ++n )
; ;
return n; return n;
} }
#endif #endif
void *icalalloc (yy_size_t size ) void *icalalloc (yy_size_t size )
{ {
return (void *) malloc( size ); return (void *) malloc( size );
} }
void *icalrealloc (void * ptr, yy_size_t size ) void *icalrealloc (void * ptr, yy_size_t size )
{ {
/* The cast to (char *) in the following accommodates both /* The cast to (char *) in the following accommodates both
* implementations that use char* generic pointers, and those * implementations that use char* generic pointers, and those
* that use void* generic pointers. It works with the latter * that use void* generic pointers. It works with the latter
* because both ANSI C and C++ allow castless assignment from * because both ANSI C and C++ allow castless assignment from
* any pointer type to void*, and deal with argument conversions * any pointer type to void*, and deal with argument conversions
* as though doing an assignment. * as though doing an assignment.
*/ */
return (void *) realloc( (char *) ptr, size ); return (void *) realloc( (char *) ptr, size );
} }
void icalfree (void * ptr ) void icalfree (void * ptr )
{ {
free( (char *) ptr ); /* see icalrealloc() for (char *) cast */ free( (char *) ptr ); /* see icalrealloc() for (char *) cast */
} }
#define YYTABLES_NAME "yytables" #define YYTABLES_NAME "yytables"
#line 288 "sbr/icalendar.l" #line 288 "sbr/icalendar.l"
static char * static char *
unfold (char *text, size_t *leng) { unfold (char *text, size_t *leng) {
/* It's legal to shorten text and modify leng (because we don't /* It's legal to shorten text and modify leng (because we don't
use yymore()). */ use yymore()). */
 End of changes. 67 change blocks. 
101 lines changed or deleted 67 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)