NAME

caterr_setdebug - parse a debug specification

SYNOPSIS

#include <cat/cat.h>

void caterr_setdebug(const char *spec);

DESCRIPTION

This function takes a debug specification string and sets up the debug prefix, debug level, output file, and a list of selected labels to be traced.

The specification is a list of elements separated by a ``;'' character. Elements can be as follows:

>filename
Set debug output file (uses caterr_setfile())

[0-9]
Set global debug level.

=prefix
Set debug output prefix (see caterr_setprefix())

label
Select labels or prefixes for labels.

!label
Deselect labels.

+t
Use timestamp prefix. Uses caterr_setprefix() to set the prefix string "%p %n[%s] +%t %f: ".

Typical usage is ``4'', to set only the debug level and use default values for everything else, or ``4;>/tmp/output'' to redirect output to a file.

SEE ALSO

cat, caterr, caterr_setfile, caterr_setprefix