X-Git-Url: https://git.kernel.dk/?p=fio.git;a=blobdiff_plain;f=debug.c;h=d1e2987ba3e7c1004487bcacd858ade03944a12a;hp=2eb3b6f932be7b9fd398beac920e5a928872928e;hb=01bf5128d0581e267383f280c6a1dcd26517240f;hpb=bf84eacbfc91a952eb5b781ad2955109c862d41e diff --git a/debug.c b/debug.c index 2eb3b6f9..d1e2987b 100644 --- a/debug.c +++ b/debug.c @@ -1,27 +1,18 @@ +#include #include -#include -#include + #include "debug.h" +#include "log.h" +#ifdef FIO_INC_DEBUG void __dprint(int type, const char *str, ...) { va_list args; - pid_t pid; assert(type < FD_DEBUG_MAX); - if ((((1 << type)) & fio_debug) == 0) - return; - - pid = getpid(); - if (fio_debug_jobp && *fio_debug_jobp != -1U - && pid != *fio_debug_jobp) - return; - - log_info("%-8s ", debug_levels[(type)].name); - log_info("%-5u ", (int) pid); - va_start(args, str); - vfprintf(f_out, str, args); + log_prevalist(type, str, args); va_end(args); } +#endif