From 447ab1bf2b321d2cfd9af0ffc0d4c3a8b28e66a8 Mon Sep 17 00:00:00 2001 From: Peter Bieringer Date: Thu, 4 Feb 2021 08:11:08 +0100 Subject: fix log levels --- plugin.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'plugin.c') diff --git a/plugin.c b/plugin.c index 073d67a..18e8584 100644 --- a/plugin.c +++ b/plugin.c @@ -341,14 +341,14 @@ void cPluginGraphLCD::MainThreadHook() { if (mDisplay[index].Disp->Active()) { - dsyslog("graphlcd plugin: DEBUG: Display thread for %s is ready", mDisplay[index].Name.c_str()); + isyslog("graphlcd plugin: INFO: Display thread for %s is ready", mDisplay[index].Name.c_str()); mDisplay[index].Status = CONNECTED; } else { if ( (cTimeMs::Now() - mDisplay[index].to_timestamp) > (uint64_t) 10000) { - dsyslog ("graphlcd plugin: DEBUG: Timeout while waiting for display thread %s", mDisplay[index].Name.c_str()); + esyslog ("graphlcd plugin: ERROR: Timeout while waiting for display thread %s", mDisplay[index].Name.c_str()); /* no activity after 10 secs: display is unusable */ //GraphLCDSetup.PluginActive = 0; DisconnectDisplay(index); -- cgit v1.2.3 From 20bc36f46418f94eb87dbf8726e42a57fcc1a972 Mon Sep 17 00:00:00 2001 From: Peter Bieringer Date: Thu, 4 Feb 2021 08:12:38 +0100 Subject: fix Wliteral-suffix --- plugin.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'plugin.c') diff --git a/plugin.c b/plugin.c index 18e8584..f8c2de9 100644 --- a/plugin.c +++ b/plugin.c @@ -128,7 +128,7 @@ cPluginGraphLCD::~cPluginGraphLCD() const char * cPluginGraphLCD::CommandLineHelp() { - return " -c, --config=CFG use CFG as driver config file (default is \""PLUGIN_GRAPHLCDCONF"\")\n" + return " -c, --config=CFG use CFG as driver config file (default is \"" PLUGIN_GRAPHLCDCONF "\")\n" " -d, --display=DISP[,DISP]... use display DISP for output or if DISP=none: start w/o any display\n" " -s, --skin=SKIN[,SKIN]... use skin SKIN (default is \"default\")\n" " -p, --skinspath=PATH use path PATH for skins (default is \"/skins/\")\n"; -- cgit v1.2.3 From 0d5decc077e8263db8f9cd4336fe53f6d52d3234 Mon Sep 17 00:00:00 2001 From: Peter Bieringer Date: Thu, 4 Feb 2021 08:14:17 +0100 Subject: fix Wformat-truncation --- plugin.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'plugin.c') diff --git a/plugin.c b/plugin.c index f8c2de9..bfe2702 100644 --- a/plugin.c +++ b/plugin.c @@ -510,9 +510,9 @@ cString cPluginGraphLCD::SVDRPCommand(const char *Command, const char *Option, i } } } - char buf[25]; + char buf[64]; std::string retval = "RECONNECT status: "; - snprintf(buf, 24, "OK = %1d, FAILED = %1d", count_ok, count_fail); + snprintf(buf, sizeof(buf), "OK = %1d, FAILED = %1d", count_ok, count_fail); retval += buf; return retval.c_str(); } -- cgit v1.2.3