summaryrefslogtreecommitdiff
path: root/skins.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2019-05-29 16:44:55 +0200
committerKlaus Schmidinger <vdr@tvdr.de>2019-05-29 16:44:55 +0200
commit0873d146141bb86a24f2e9806b73362f49bc7d52 (patch)
tree075bd386ac9dceb4064d354c7613ae2a2a6bfd29 /skins.c
parent712523f0040ec18846ded1dea8d1838e80566f02 (diff)
downloadvdr-0873d146141bb86a24f2e9806b73362f49bc7d52.tar.gz
vdr-0873d146141bb86a24f2e9806b73362f49bc7d52.tar.bz2
If cSkins::Message() is called from a background thread and Type is not mtStatus, the call is now automatically forwarded to QueueMessage()
Diffstat (limited to 'skins.c')
-rw-r--r--skins.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/skins.c b/skins.c
index b5c447b0..47b330e2 100644
--- a/skins.c
+++ b/skins.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: skins.c 4.1 2018/04/28 12:13:01 kls Exp $
+ * $Id: skins.c 4.2 2019/05/29 16:43:09 kls Exp $
*/
#include "skins.h"
@@ -250,7 +250,10 @@ bool cSkins::SetCurrent(const char *Name)
eKeys cSkins::Message(eMessageType Type, const char *s, int Seconds)
{
if (!cThread::IsMainThread()) {
- dsyslog("cSkins::Message() called from background thread - ignored! (Use cSkins::QueueMessage() instead)");
+ if (Type != mtStatus)
+ QueueMessage(Type, s, Seconds);
+ else
+ dsyslog("cSkins::Message(%d, \"%s\", %d) called from background thread - ignored! (Use cSkins::QueueMessage() instead)", Type, s, Seconds);
return kNone;
}
switch (Type) {