File tree Expand file tree Collapse file tree 2 files changed +18
-4
lines changed
Expand file tree Collapse file tree 2 files changed +18
-4
lines changed Original file line number Diff line number Diff line change @@ -69,7 +69,7 @@ If accessing from Git, be sure to pull submodules:
6969
7070Build:
7171
72- ./configure
72+ ./configure --qtselect=5
7373 make
7474
7575Run:
Original file line number Diff line number Diff line change @@ -275,10 +275,24 @@ class App::Private : public QObject
275275 return ;
276276 }
277277
278+ int logLevel = LOG_LEVEL_INFO;
279+ QString logLevelString = options.value (" loglevel" );
280+ if (!logLevelString.isEmpty ())
281+ {
282+ bool ok;
283+ logLevel = logLevelString.toInt (&ok);
284+ if (!ok || logLevel < LOG_LEVEL_ERROR)
285+ {
286+ log_error (" parameter to --loglevel invalid: %s" , qPrintable (logLevelString));
287+ emit q->quit ();
288+ return ;
289+ }
290+ }
291+
278292 if (options.contains (" verbose" ))
279- log_setOutputLevel ( LOG_LEVEL_DEBUG) ;
280- else
281- log_setOutputLevel (LOG_LEVEL_INFO );
293+ logLevel = LOG_LEVEL_DEBUG;
294+
295+ log_setOutputLevel (logLevel );
282296
283297 QString logFile = options.value (" logfile" );
284298 if (!logFile.isEmpty ())
You can’t perform that action at this time.
0 commit comments