Do not declare a symbol "link" because this conflicts with the system call

2006-08-05  Raphael Quinet  <raphael@gimp.org>

	* plug-ins/imagemap/imap_ncsa.l: Do not declare a symbol "link"
	because this conflicts with the system call declared in
	<unistd.h>.  Renamed that symbol "imap_link".  Fixes bug #349589.

	* plug-ins/imagemap/imap_ncsa_lex.c: Updated by hand in order to
	avoid large changes introduced by more recent versions of flex.
This commit is contained in:
Raphael Quinet 2006-08-04 22:12:44 +00:00 committed by Raphaël Quinet
parent 4ad66b8659
commit 7c245e1654
3 changed files with 21 additions and 12 deletions

View file

@ -1,3 +1,12 @@
2006-08-05 Raphaël Quinet <raphael@gimp.org>
* plug-ins/imagemap/imap_ncsa.l: Do not declare a symbol "link"
because this conflicts with the system call declared in
<unistd.h>. Renamed that symbol "imap_link". Fixes bug #349589.
* plug-ins/imagemap/imap_ncsa_lex.c: Updated by hand in order to
avoid large changes introduced by more recent versions of flex.
2006-08-04 Raphaël Quinet <raphael@gimp.org>
* tools/pdbgen/stddefs.pdb

View file

@ -38,7 +38,7 @@ DIGIT [0-9]
ID [a-zA-Z_][a-zA-Z0-9_\-]*
WS [ \t\n]+
%x link
%x imap_link
%x comment
%%
@ -70,26 +70,26 @@ WS [ \t\n]+
}
RECT {
BEGIN(link);
BEGIN(imap_link);
return RECTANGLE;
}
CIRCLE {
BEGIN(link);
BEGIN(imap_link);
return CIRCLE;
}
POLY {
BEGIN(link);
BEGIN(imap_link);
return POLYGON;
}
DEFAULT {
BEGIN(link);
BEGIN(imap_link);
return DEFAULT;
}
<link>[^ ,\t\n]+ {
<imap_link>[^ ,\t\n]+ {
BEGIN(INITIAL);
strcpy(ncsa_lval.id, yytext);
ncsa_lval.id[yyleng - 1] = '\0';

View file

@ -460,7 +460,7 @@ char *yytext;
#include <string.h>
#include "imap_ncsa_parse.h"
#define link 1
#define imap_link 1
#define comment 2
@ -746,7 +746,7 @@ case 6:
YY_RULE_SETUP
#line 65 "imap_ncsa.l"
{
BEGIN(link);
BEGIN(imap_link);
return RECTANGLE;
}
YY_BREAK
@ -754,7 +754,7 @@ case 7:
YY_RULE_SETUP
#line 70 "imap_ncsa.l"
{
BEGIN(link);
BEGIN(imap_link);
return CIRCLE;
}
YY_BREAK
@ -762,7 +762,7 @@ case 8:
YY_RULE_SETUP
#line 75 "imap_ncsa.l"
{
BEGIN(link);
BEGIN(imap_link);
return POLYGON;
}
YY_BREAK
@ -770,7 +770,7 @@ case 9:
YY_RULE_SETUP
#line 80 "imap_ncsa.l"
{
BEGIN(link);
BEGIN(imap_link);
return DEFAULT;
}
YY_BREAK
@ -809,7 +809,7 @@ ECHO;
YY_BREAK
#line 809 "imap_ncsa_lex.c"
case YY_STATE_EOF(INITIAL):
case YY_STATE_EOF(link):
case YY_STATE_EOF(imap_link):
case YY_STATE_EOF(comment):
yyterminate();