Convert lexer to talloc and add xtalloc wrappers.
authorCarl Worth <cworth@cworth.org>
Wed, 12 May 2010 19:45:33 +0000 (12:45 -0700)
committerCarl Worth <cworth@cworth.org>
Wed, 12 May 2010 19:47:29 +0000 (12:47 -0700)
commit5070a20cd1e65d52856bd74558f9a34f8dca114f
treea8cd5b178480c7b670b0a8e63ccd15dff190c7b3
parent33cc400714f379ef13e876b4aedd0de8cb5d033d
Convert lexer to talloc and add xtalloc wrappers.

The lexer was previously using strdup (expecting the parser to free),
but is now more consistent, easier to use, and slightly more efficent
by using talloc along with the parser.

Also, we add xtalloc and xtalloc_strdup wrappers around talloc and
talloc_strdup to put all of the out-of-memory-checking code in one
place.
Makefile
glcpp-lex.l
glcpp-parse.y
glcpp.h
xtalloc.c [new file with mode: 0644]