antlr3 icon indicating copy to clipboard operation
antlr3 copied to clipboard

newPool() allocates memory without checking for NULL

Open murrayju opened this issue 11 years ago • 0 comments

In antlr3collections.c, the function newPool() is calling both realloc and malloc without properly handling the out of memory (NULL return) case.

This ultimately leads to my application crashing in antlr3commontoken.c, in newPoolToken() with an access violation caused by a NULL pointer dereference.

murrayju avatar Feb 06 '13 14:02 murrayju