diff options
author | Mattias Andrée <maandree@operamail.com> | 2014-11-16 23:20:18 +0100 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2014-11-16 23:20:18 +0100 |
commit | 9f78a6069456e05c66eb864f066d2a1d6ea4bdea (patch) | |
tree | 36f93954de8ea18f7c23c09020609f99bb0653a2 /src/mds-kbdc | |
parent | print parsed tree, of course there are some errors... (diff) | |
download | mds-9f78a6069456e05c66eb864f066d2a1d6ea4bdea.tar.gz mds-9f78a6069456e05c66eb864f066d2a1d6ea4bdea.tar.bz2 mds-9f78a6069456e05c66eb864f066d2a1d6ea4bdea.tar.xz |
m
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to 'src/mds-kbdc')
-rw-r--r-- | src/mds-kbdc/make-tree.c | 1 | ||||
-rw-r--r-- | src/mds-kbdc/mds-kbdc.c | 3 |
2 files changed, 3 insertions, 1 deletions
diff --git a/src/mds-kbdc/make-tree.c b/src/mds-kbdc/make-tree.c index 5caaa72..37ed34c 100644 --- a/src/mds-kbdc/make-tree.c +++ b/src/mds-kbdc/make-tree.c @@ -935,6 +935,7 @@ int parse_to_tree(const char* restrict filename, mds_kbdc_tree_t** restrict resu #define node supernode #define inner sequence NEW_NODE(map, MAP); /* FIXME memory leak */ + node->loc_end = node->loc_start; BRANCH(":"); #undef inner #undef node diff --git a/src/mds-kbdc/mds-kbdc.c b/src/mds-kbdc/mds-kbdc.c index ef058ba..82702c4 100644 --- a/src/mds-kbdc/mds-kbdc.c +++ b/src/mds-kbdc/mds-kbdc.c @@ -45,6 +45,7 @@ int main(int argc_, char** argv_) argv = argv_; fail_if (parse_to_tree(argv[1], &tree, &parse_errors) < 0); + mds_kbdc_tree_print(tree, stderr); if (parse_errors != NULL) { mds_kbdc_parse_error_t** errors = parse_errors; @@ -57,7 +58,7 @@ int main(int argc_, char** argv_) } mds_kbdc_parse_error_free_all(parse_errors); if (fatal) - return mds_kbdc_tree_print(tree, stderr), mds_kbdc_tree_free(tree), 1; + return mds_kbdc_tree_free(tree), 1; } mds_kbdc_tree_free(tree); |