diff options
author | Daniel Veillard <veillard@src.gnome.org> | 2003-02-16 15:44:18 +0000 |
---|---|---|
committer | Daniel Veillard <veillard@src.gnome.org> | 2003-02-16 15:44:18 +0000 |
commit | febcca40d43b41df4fb202d6c96104c5aae6c68d (patch) | |
tree | 1a5df826ec469582d48077058470c88a49af11b6 /testRelax.c | |
parent | d2298791af5f9104e5cbd9f58c731f2116195bcd (diff) | |
download | android_external_libxml2-febcca40d43b41df4fb202d6c96104c5aae6c68d.tar.gz android_external_libxml2-febcca40d43b41df4fb202d6c96104c5aae6c68d.tar.bz2 android_external_libxml2-febcca40d43b41df4fb202d6c96104c5aae6c68d.zip |
more bug-hunting added --tree to dump the intermediate rng tree patch from
* relaxng.c: more bug-hunting
* testRelax.c include/libxml/relaxng.h: added --tree to dump the
intermediate rng tree
* python/generator.py: patch from Stephane Bidoul to fix the generator
on python < 2.2
Daniel
Diffstat (limited to 'testRelax.c')
-rw-r--r-- | testRelax.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/testRelax.c b/testRelax.c index 354e71e6..c930b519 100644 --- a/testRelax.c +++ b/testRelax.c @@ -48,6 +48,7 @@ static int debug = 0; #endif static int noout = 0; +static int tree = 0; #ifdef HAVE_SYS_MMAN_H static int memory = 0; #endif @@ -71,6 +72,9 @@ int main(int argc, char **argv) { #endif if ((!strcmp(argv[i], "-noout")) || (!strcmp(argv[i], "--noout"))) { noout++; + } else + if ((!strcmp(argv[i], "-tree")) || (!strcmp(argv[i], "--tree"))) { + tree++; } } xmlLineNumbersDefault(1); @@ -123,6 +127,8 @@ int main(int argc, char **argv) { if (debug) xmlRelaxNGDump(stdout, schema); #endif + if (tree) + xmlRelaxNGDumpTree(stdout, schema); } else { xmlDocPtr doc; @@ -165,6 +171,7 @@ int main(int argc, char **argv) { printf("\t--debug : dump a debug tree of the in-memory document\n"); #endif printf("\t--noout : do not print the result\n"); + printf("\t--tree : print the intermediate Relax-NG document tree\n"); #ifdef HAVE_SYS_MMAN_H printf("\t--memory : test the schemas in memory parsing\n"); #endif |