From 93f4852ba3fc69533a05021200d4b707291df94f Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Thu, 12 Jun 2014 08:55:32 +0200 Subject: Fixed a possible crash in the LCARS skin --- skinlcars.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'skinlcars.c') diff --git a/skinlcars.c b/skinlcars.c index e9d1e28f..a722b521 100644 --- a/skinlcars.c +++ b/skinlcars.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: skinlcars.c 3.7 2014/03/10 12:04:06 kls Exp $ + * $Id: skinlcars.c 3.8 2014/06/12 08:48:15 kls Exp $ */ // "Star Trek: The Next Generation"(R) is a registered trademark of Paramount Pictures, @@ -482,7 +482,7 @@ cSkinLCARSDisplayChannel::~cSkinLCARSDisplayChannel() void cSkinLCARSDisplayChannel::DrawDate(void) { cString s = DayDateTime(); - if (initial || strcmp(s, lastDate)) { + if (initial || !*lastDate || strcmp(s, lastDate)) { osd->DrawText(xc12, yc11, s, Theme.Color(clrDateFg), Theme.Color(clrDateBg), cFont::GetFont(fontOsd), xc13 - xc12, lineHeight, taRight | taBorder); lastDate = s; } @@ -1070,7 +1070,7 @@ void cSkinLCARSDisplayMenu::DrawMenuFrame(void) void cSkinLCARSDisplayMenu::DrawDate(void) { cString s = DayDateTime(); - if (initial || strcmp(s, lastDate)) { + if (initial || !*lastDate || strcmp(s, lastDate)) { const cFont *font = cFont::GetFont(fontOsd); tColor ColorFg = Theme.Color(clrDateFg); tColor ColorBg = Theme.Color(clrDateBg); -- cgit v1.2.3