diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2009-11-25 15:46:54 -0800 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2009-11-25 15:46:54 -0800 |
commit | 3c784ae4f4b25ebcc4019b77c77a7e365fdac261 (patch) | |
tree | 6f6dd9edeb85051baa617f72268c6704c4d64d97 /txr.c | |
parent | 1dc59ff8a80f2635785bef5c50fb3f7e815f060d (diff) | |
download | txr-3c784ae4f4b25ebcc4019b77c77a7e365fdac261.tar.gz txr-3c784ae4f4b25ebcc4019b77c77a7e365fdac261.tar.bz2 txr-3c784ae4f4b25ebcc4019b77c77a7e365fdac261.zip |
More Valgrind support. New option --vg-debug which turns on
Valgrind protection of free blocks. This works independently
of --gc-debug.
Diffstat (limited to 'txr.c')
-rw-r--r-- | txr.c | 11 |
1 files changed, 11 insertions, 0 deletions
@@ -270,6 +270,17 @@ static int txr_main(int argc, char **argv) opt_gc_debug = 1; argv++, argc--; continue; + } else if (!strcmp(*argv, "--vg-debug")) { +#ifdef HAVE_VALGRIND + opt_vg_debug = 1; + argv++, argc--; + continue; +#else + format(std_error, + lit("~a: option ~a requires Valgrind support compiled in\n"), + prog_string, string_utf8(*argv), nao); + return EXIT_FAILURE; +#endif } { |