/* dprint.c -- print out debugging info * * Calling sequence is identical to printf. dprint first checks * whether the global dflag is TRUE; if not, it exits without doing * anything. If it is true, 2*indent blanks are written to stdout * (indent is another global int), and then printf is called with the * arguments that were passed to dprint. */ #include #include #include "common.h" extern int dflag; /* debugging on? */ extern int indent; /* indent lines by */ void dprint( const char *f, ... ) { register int i; va_list ap; if (!dflag) return; for(i=0; i