diff options
| author | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2012-02-25 17:41:26 +0100 |
|---|---|---|
| committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2012-02-25 17:41:26 +0100 |
| commit | 89f8067dd732fe402c3c5f8380bb5649fe02d1a4 (patch) | |
| tree | 26c49685853b85c409d96ab6b547e6eee7b6e5e5 /libddekit/ddekit/printf.h | |
| parent | 816140d6c6cd5f369dc8d92031128279d0c44fd2 (diff) | |
| parent | 29af9988d7213fcccf11011159261b94af4f1bee (diff) | |
Merge branch 'master' of git.debian.org:/git/pkg-hurd/hurd
Conflicts:
debian/changelog
Diffstat (limited to 'libddekit/ddekit/printf.h')
| -rw-r--r-- | libddekit/ddekit/printf.h | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/libddekit/ddekit/printf.h b/libddekit/ddekit/printf.h new file mode 100644 index 00000000..6dafa18d --- /dev/null +++ b/libddekit/ddekit/printf.h @@ -0,0 +1,35 @@ +#ifndef _ddekit_print_h +#define _ddekit_print_h + +#include <stdarg.h> + +/** Print message. + * \ingroup DDEKit_util + */ +int ddekit_print(const char *); + +/** Print message with format. + * \ingroup DDEKit_util + */ +int ddekit_printf(const char *fmt, ...); + +/** Print message with format list. + * \ingroup DDEKit_util + */ +int ddekit_vprintf(const char *fmt, va_list va); + +void dump_stack(void); + +/** Log function and message. + * \ingroup DDEKit_util + */ +#define ddekit_log(doit, msg...) \ + do { \ + if (doit) { \ + ddekit_printf("%s(): ", __func__); \ + ddekit_printf(msg); \ + ddekit_printf("\n"); \ + } \ + } while(0); + +#endif |
