Deleted Added
full compact
token.l (125681) token.l (126843)
1/* $FreeBSD: head/sbin/setkey/token.l 125681 2004-02-11 04:34:34Z bms $ */
1/* $FreeBSD: head/sbin/setkey/token.l 126843 2004-03-11 11:41:54Z bde $ */
2/* $KAME: token.l,v 1.43 2003/07/25 09:35:28 itojun Exp $ */
3
4/*
5 * Copyright (C) 1995, 1996, 1997, 1998, and 1999 WIDE Project.
6 * All rights reserved.
7 *
8 * Redistribution and use in source and binary forms, with or without
9 * modification, are permitted provided that the following conditions

--- 95 unchanged lines hidden (view full) ---

105tagged { return(TAGGED); }
106{hyphen}P { BEGIN S_PL; return(F_POLICY); }
107<S_PL>[a-zA-Z0-9:\.\-_/ \n\t][a-zA-Z0-9:\.%\-_/ \n\t]* {
108 yymore();
109
110 /* count up for nl */
111 {
112 char *p;
2/* $KAME: token.l,v 1.43 2003/07/25 09:35:28 itojun Exp $ */
3
4/*
5 * Copyright (C) 1995, 1996, 1997, 1998, and 1999 WIDE Project.
6 * All rights reserved.
7 *
8 * Redistribution and use in source and binary forms, with or without
9 * modification, are permitted provided that the following conditions

--- 95 unchanged lines hidden (view full) ---

105tagged { return(TAGGED); }
106{hyphen}P { BEGIN S_PL; return(F_POLICY); }
107<S_PL>[a-zA-Z0-9:\.\-_/ \n\t][a-zA-Z0-9:\.%\-_/ \n\t]* {
108 yymore();
109
110 /* count up for nl */
111 {
112 char *p;
113 for (p = yytext; *p != NULL; p++)
113 for (p = yytext; *p != '\0'; p++)
114 if (*p == '\n')
115 lineno++;
116 }
117
118 yylval.val.len = strlen(yytext);
119 yylval.val.buf = strdup(yytext);
120 if (!yylval.val.buf)
121 yyfatal("insufficient memory");

--- 94 unchanged lines hidden (view full) ---

216 yylval.val.len = strlen(yylval.val.buf);
217
218 return(HEXSTRING);
219 }
220
221{quotedstring} {
222 char *p = yytext;
223 while (*++p != '"') ;
114 if (*p == '\n')
115 lineno++;
116 }
117
118 yylval.val.len = strlen(yytext);
119 yylval.val.buf = strdup(yytext);
120 if (!yylval.val.buf)
121 yyfatal("insufficient memory");

--- 94 unchanged lines hidden (view full) ---

216 yylval.val.len = strlen(yylval.val.buf);
217
218 return(HEXSTRING);
219 }
220
221{quotedstring} {
222 char *p = yytext;
223 while (*++p != '"') ;
224 *p = NULL;
224 *p = '\0';
225 yytext++;
226 yylval.val.len = yyleng - 2;
227 yylval.val.buf = strdup(yytext);
228 if (!yylval.val.buf)
229 yyfatal("insufficient memory");
230
231 return(QUOTEDSTRING);
232 }

--- 54 unchanged lines hidden ---
225 yytext++;
226 yylval.val.len = yyleng - 2;
227 yylval.val.buf = strdup(yytext);
228 if (!yylval.val.buf)
229 yyfatal("insufficient memory");
230
231 return(QUOTEDSTRING);
232 }

--- 54 unchanged lines hidden ---