This has failed on me at least twice. The last time involved a parser error (YYSTYPE was unknown) so there might be a race involving flex.