Truncate identifiers at NAMEDATALEN length.

This commit is contained in:
Bruce Momjian 1998-08-29 02:36:18 +00:00
parent 3e87302201
commit d15c37ca82

View File

@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/parser/scan.l,v 1.40 1998/06/16 07:29:27 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/parser/scan.l,v 1.41 1998/08/29 02:36:18 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@ -323,6 +323,8 @@ other .
if (isascii((unsigned char)yytext[i]) &&
isupper(yytext[i]))
yytext[i] = tolower(yytext[i]);
if (i > NAMEDATALEN)
yytext[NAMEDATALEN] = '\0';
keyword = ScanKeywordLookup((char*)yytext);
if (keyword != NULL) {
@ -400,6 +402,8 @@ other .
if (isascii((unsigned char)yytext[i]) &&
isupper(yytext[i]))
yytext[i] = tolower(yytext[i]);
if (i > NAMEDATALEN)
yytext[NAMEDATALEN] = '\0';
keyword = ScanKeywordLookup((char*)yytext);
if (keyword != NULL) {