2 * Copyright (C) 1995-2005, Index Data ApS
3 * See the file LICENSE for details.
5 * $Id: tstlog.c,v 1.6 2005-09-08 13:22:58 adam Exp $
10 #include <yaz/options.h>
13 int main(int argc, char **argv)
20 while ((ret = options("f:v:l:m:n:s:", argv, argc, &arg)) != -2)
25 yaz_log_init_max_size(atoi(arg));
28 yaz_log_time_format(arg);
31 yaz_log_init_level(yaz_log_mask_str(arg));
34 yaz_log_init_file(arg);
40 level = yaz_log_module_level(arg);
43 for (i = 0; i<number; i++)
44 yaz_log(level, "%s", arg);
47 fprintf(stderr, "tstlog. Bad option\n");
48 fprintf(stderr, "tstlog [-f logformat] [-v level] [-l file] "
49 "[-m module] msg ..\n");
58 * indent-tabs-mode: nil
60 * vim: shiftwidth=4 tabstop=8 expandtab