diff options
author | Gwenhael Goavec-Merou <gwenhael.goavec-merou@trabucayre.com> | 2023-07-02 07:10:14 +0200 |
---|---|---|
committer | Eric Wild <ewild@sysmocom.de> | 2024-05-15 19:40:15 +0200 |
commit | a6afeaa3a1038e64751616d769537cd22ace015d (patch) | |
tree | ac101735e43b4776ffc3f5139b2d95cf1b4b9dc2 | |
parent | 39ef03d9615fa369ce7666b1a8e02673c165cbf3 (diff) |
lib/xtrx: honouring/using the loglevel parameterv0.2.6
loglevel parameter is never used and let loglevel to DEBUG, with an
annoying flood of message in terminal.
This patch adds a call to xtrx_log_setlevel() at xtrx constructor level.
Signed-off-by: Gwenhael Goavec-Merou <gwenhael.goavec-merou@trabucayre.com>
Signed-off-by: Eric Wild <ewild@sysmocom.de>
-rw-r--r-- | lib/xtrx/xtrx_obj.cc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/xtrx/xtrx_obj.cc b/lib/xtrx/xtrx_obj.cc index 016b420..ab32a7f 100644 --- a/lib/xtrx/xtrx_obj.cc +++ b/lib/xtrx/xtrx_obj.cc @@ -68,6 +68,8 @@ xtrx_obj::xtrx_obj(const std::string &path, unsigned loglevel, bool lmsreset) unsigned xtrxflag = (loglevel & XTRX_O_LOGLVL_MASK) | ((lmsreset) ? XTRX_O_RESET : 0); std::cerr << "xtrx_obj::xtrx_obj = " << xtrxflag << std::endl; + xtrx_log_setlevel(loglevel, NULL); + int res = xtrx_open_string(path.c_str(), &_obj); if (res < 0) { std::stringstream message; |