From: Adam Dickmeiss Date: Fri, 8 Sep 2006 09:56:40 +0000 (+0000) Subject: Dont override log level (e.g. when set with YAZ_LOG env) X-Git-Tag: ZEBRA.2.0.2~24 X-Git-Url: http://git.indexdata.com/?p=idzebra-moved-to-github.git;a=commitdiff_plain;h=9aacfd0955fc70f27165254a2844618c85e8600d;hp=94c8b65c0a0eafb2b1e3cf70ed63e1d0f4341a5d Dont override log level (e.g. when set with YAZ_LOG env) --- diff --git a/test/api/testlib.c b/test/api/testlib.c index 31c9219..5735254 100644 --- a/test/api/testlib.c +++ b/test/api/testlib.c @@ -1,4 +1,4 @@ -/* $Id: testlib.c,v 1.37 2006-08-31 08:36:53 adam Exp $ +/* $Id: testlib.c,v 1.38 2006-09-08 09:56:40 adam Exp $ Copyright (C) 1995-2006 Index Data ApS @@ -44,7 +44,6 @@ int log_level=0; /* not static, t*.c may use it */ void tl_start_log(int argc, char **argv) { - int cmd_level = 0; char logname[2048]; if (!argv) return; @@ -59,7 +58,8 @@ void tl_start_log(int argc, char **argv) log_level = yaz_log_mask_str_x(argv[1], 0); if (argc >= 3) yaz_log_time_format(argv[2]); - yaz_log_init_level(YLOG_DEFAULT_LEVEL | log_level | cmd_level); + if (log_level) + yaz_log_init_level(log_level); yaz_log(log_level, "starting %s", argv[0]); }