[antlr-interest] [C] Crashes if NULL name in antlr3StringStreamNew()
Ruslan Zasukhin
ruslan_zasukhin at valentina-db.com
Tue Aug 30 06:17:00 PDT 2011
If I call
input = antlr3StringStreamNew(
input_string, Encoding, input_len, NULL );
NULL is name of stream
Then it crashes inside of
newStr8 (pANTLR3_STRING_FACTORY factory, pANTLR3_UINT8 ptr)
{
return factory->newPtr8(factory, ptr,
(ANTLR3_UINT32)strlen((const char *)ptr)); <<<<<< crash
}
Because on mac and linux strlen() crashes on NULL.
--
Best regards,
Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc
Valentina - Joining Worlds of Information
http://www.paradigmasoft.com
[I feel the need: the need for speed]
More information about the antlr-interest
mailing list