diff options
author | Klaus Schmidinger <vdr@tvdr.de> | 2016-12-22 14:13:42 +0100 |
---|---|---|
committer | Klaus Schmidinger <vdr@tvdr.de> | 2016-12-22 14:13:42 +0100 |
commit | 39c9fc11993609dbe1d8de7a3811c25403d3049e (patch) | |
tree | 04d68dd94371b3217aeeaf86bcdb35036788e3ec /skinclassic.c | |
parent | 99dfe9f66a5e33ab0ce55850f57901bf5fe11692 (diff) | |
download | vdr-39c9fc11993609dbe1d8de7a3811c25403d3049e.tar.gz vdr-39c9fc11993609dbe1d8de7a3811c25403d3049e.tar.bz2 |
Fixed truncated date/time strings in the skins on multi-byte UTF-8 systems
Diffstat (limited to 'skinclassic.c')
-rw-r--r-- | skinclassic.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/skinclassic.c b/skinclassic.c index b9919d84..26408993 100644 --- a/skinclassic.c +++ b/skinclassic.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: skinclassic.c 2.10 2013/03/03 15:26:09 kls Exp $ + * $Id: skinclassic.c 4.1 2016/12/22 14:07:04 kls Exp $ */ #include "skinclassic.h" @@ -352,8 +352,7 @@ void cSkinClassicDisplayMenu::SetEvent(const cEvent *Event) const cFont *font = cFont::GetFont(fontOsd); int y = y2; cTextScroller ts; - char t[32]; - snprintf(t, sizeof(t), "%s %s - %s", *Event->GetDateString(), *Event->GetTimeString(), *Event->GetEndTimeString()); + cString t = cString::sprintf("%s %s - %s", *Event->GetDateString(), *Event->GetTimeString(), *Event->GetEndTimeString()); ts.Set(osd, x1, y, x2 - x1, y3 - y, t, font, Theme.Color(clrMenuEventTime), Theme.Color(clrBackground)); if (Event->Vps() && Event->Vps() != Event->StartTime()) { cString buffer = cString::sprintf(" VPS: %s ", *Event->GetVpsString()); |