summaryrefslogtreecommitdiff
path: root/dtc-lexer.l
diff options
context:
space:
mode:
authorScott Wood <scottwood@freescale.com>2008-01-07 14:27:36 -0600
committerJon Loeliger <jdl@freescale.com>2008-01-07 14:36:41 -0600
commit42107f8bba994f718594dd670a937861d40f425d (patch)
treea0f4721f00f597a7be7d17822dc5ce62515daa8d /dtc-lexer.l
parent3c3ecaacda4f7ef201d02682382a64674661cae3 (diff)
downloaddtc-42107f8bba994f718594dd670a937861d40f425d.tar.gz
Convert malloc() uses to xmalloc().
Signed-off-by: Scott Wood <scottwood@freescale.com>
Diffstat (limited to 'dtc-lexer.l')
-rw-r--r--dtc-lexer.l6
1 files changed, 1 insertions, 5 deletions
diff --git a/dtc-lexer.l b/dtc-lexer.l
index bfb996e..f2836a8 100644
--- a/dtc-lexer.l
+++ b/dtc-lexer.l
@@ -273,11 +273,7 @@ int push_input_file(const char *filename)
exit(1);
}
- incl_file = malloc(sizeof(struct incl_file));
- if (!incl_file) {
- yyerror("Can not allocate include file space.");
- return 0;
- }
+ incl_file = xmalloc(sizeof(struct incl_file));
/*
* Save current context.