[postgis-devel] Possible server crash detected

Michael Fuhr mike at fuhr.org
Tue Apr 18 08:33:26 PDT 2006


On Tue, Apr 18, 2006 at 02:49:48PM +0200, strk at refractions.net wrote:
> I've fixed the WKT parser to forbid EMPTY elements in multigeometries.
> I think it makes sense. Also, if such objects are constructed with
> any other mean I added some checks in the code to raise an error
> rathern then crashing the backend. Crash tests welcome.

On Solaris 9 yacc doesn't like the new code:

/usr/ccs/bin/yacc -vd -p lwg_parse_yy wktparse.y
"wktparse.y", line 216: fatal: illegal comment
gmake[1]: *** [wktparse.tab.c] Error 1

Changing the // comment to /* */ satisfies yacc but the build soon
fails again:

wktparse.lex: In function `lwg_parse_yylex':
wktparse.lex:28: error: `lwg_parse_yylval' undeclared (first use in this function)
wktparse.lex:28: error: (Each undeclared identifier is reported only once
wktparse.lex:28: error: for each function it appears in.)
wktparse.lex: At top level:
lex.yy.c:3027: warning: 'yyunput' defined but not used
gmake[1]: *** [lex.yy.o] Error 1

I don't know if this is the proper solution, but if I edit configure.in
and change

  AC_SUBST(YACC)
  AC_PATH_PROG([YACC], [yacc])

to

  AC_PROG_YACC

and run autogen.sh and configure again, then the build succeeds
(using bison -y instead of yacc) and all tests pass.

On my FreeBSD 6.1-PRERELEASE box the code builds and passes all
tests without any changes.

-- 
Michael Fuhr



More information about the postgis-devel mailing list