From: Andi Gutmans Date: Sun, 17 Dec 2000 20:10:16 +0000 (+0000) Subject: - %> without asp_tags should not be treated as inline_html but as regular X-Git-Tag: php-4.0.5RC1~869 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6529b066187f0e37ca8f4a25c501d49b9a739947;p=php - %> without asp_tags should not be treated as inline_html but as regular tokens. Of course the parser will die with a parse error which is the correct behavior. --- diff --git a/Zend/zend_language_scanner.l b/Zend/zend_language_scanner.l index 5711b3db41..497cc14e21 100644 --- a/Zend/zend_language_scanner.l +++ b/Zend/zend_language_scanner.l @@ -1238,16 +1238,16 @@ ANY_CHAR (.|[\n]) "%>"([\n]|"\r\n")? { - zendlval->value.str.len = yyleng; - zendlval->type = IS_STRING; - HANDLE_NEWLINES(yytext,yyleng); if (CG(asp_tags)) { BEGIN(INITIAL); + zendlval->value.str.len = yyleng; + zendlval->type = IS_STRING; zendlval->value.str.val = yytext; /* no copying - intentional */ + HANDLE_NEWLINES(yytext,yyleng); return T_CLOSE_TAG; /* implicit ';' at php-end tag */ } else { - zendlval->value.str.val = (char *) estrndup(yytext, yyleng); - return T_INLINE_HTML; + yyless(1); + return yytext[0]; } }