diff options
author | Dimitri van Heesch <dimitri@stack.nl> | 2002-01-22 17:56:24 (GMT) |
---|---|---|
committer | Dimitri van Heesch <dimitri@stack.nl> | 2002-01-22 17:56:24 (GMT) |
commit | 61e51f0c7b139596e54aaea4c4d684b59cbfae57 (patch) | |
tree | d15a4da33ccd88d9f7ebd50a6090a12c90ccbae4 /addon/doxmlparser/src/debug.cpp | |
parent | 9d4d8095cd70a06a3536eea20c32ca7bbddd9f3a (diff) | |
download | Doxygen-61e51f0c7b139596e54aaea4c4d684b59cbfae57.zip Doxygen-61e51f0c7b139596e54aaea4c4d684b59cbfae57.tar.gz Doxygen-61e51f0c7b139596e54aaea4c4d684b59cbfae57.tar.bz2 |
Doxygen-1.2.13-20020122
Diffstat (limited to 'addon/doxmlparser/src/debug.cpp')
-rw-r--r-- | addon/doxmlparser/src/debug.cpp | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/addon/doxmlparser/src/debug.cpp b/addon/doxmlparser/src/debug.cpp new file mode 100644 index 0000000..a8be32c --- /dev/null +++ b/addon/doxmlparser/src/debug.cpp @@ -0,0 +1,24 @@ +#include <stdio.h> +#include <stdlib.h> +#include <stdarg.h> + +#include "debug.h" + +static int s_debugLevel = 0; + +void debug(int level,const char *msg,...) +{ + if (level<=s_debugLevel) + { + va_list args; + va_start(args, msg); + vfprintf(stderr, msg, args); + va_end(args); + } +} + +void setDebugLevel(int level) +{ + s_debugLevel = level; +} + |