1
0
mirror of https://github.com/VDR4Arch/vdr.git synced 2023-10-10 13:36:52 +02:00

Fixed a possible crash in the LCARS skin

This commit is contained in:
Klaus Schmidinger 2014-06-12 08:55:32 +02:00
parent 4e460da371
commit 93f4852ba3
3 changed files with 6 additions and 4 deletions

View File

@ -3260,6 +3260,7 @@ Thomas Reufer <thomas@reufer.ch>
for suggesting to add an additional parameter named Forward to cDevice::TrickSpeed()
for suggesting to add a note to ePlayMode in device.h that VDR itself always uses
pmAudioVideo when replaying a recording
for fixing a possible crash in the LCARS skin
Eike Sauer <EikeSauer@t-online.de>
for reporting a problem with channels that need more than 5 TS packets for detecting

View File

@ -8307,7 +8307,7 @@ Video Disk Recorder Revision History
- The APIVERSION has been increased to 2.0.6 due to the changes to pat.h, sdt.h and
the functional modification to cFont::CreateFont().
2014-04-14: Version 2.1.7
2014-06-12: Version 2.1.7
- No longer logging an error message in DirSizeMB() if the given directory doesn't
exist. This avoids lots of log entries in case several VDRs use the same video
@ -8319,3 +8319,4 @@ Video Disk Recorder Revision History
- Fixed a possible division by zero in frame rate detection.
- VDR now reads command line options from *.conf files in /etc/vdr/conf.d (thanks
to Lars Hanisch). See vdr.1 and vdr.5 for details.
- Fixed a possible crash in the LCARS skin (thanks to Thomas Reufer).

View File

@ -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);