diff --git a/src/gui/timerlist.cpp b/src/gui/timerlist.cpp index 7af577c72..a243b6766 100644 --- a/src/gui/timerlist.cpp +++ b/src/gui/timerlist.cpp @@ -878,7 +878,7 @@ void CTimerList::RemoteBoxTimerList(CTimerd::TimerList &rtimerlist) rtimer.alarmTime = (time_t) atoll(remotetimers[i]["alarm"][0].get("digits","").asString().c_str()); rtimer.announceTime = (time_t) atoll(remotetimers[i]["announce"][0].get("digits","").asString().c_str()); rtimer.stopTime = (time_t) atoll(remotetimers[i]["stop"][0].get("digits","").asString().c_str()); - rtimer.epgID = (event_id_t) atoi(remotetimers[i].get("epg_id","").asString()); + sscanf(remotetimers[i].get("epg_id","").asString().c_str(), SCANF_CHANNEL_ID_TYPE, &rtimer.epgID); sscanf(remotetimers[i].get("channel_id","").asString().c_str(), SCANF_CHANNEL_ID_TYPE, &rtimer.channel_id); strncpy(rtimer.epgTitle,remotetimers[i].get("title","").asString().c_str(),sizeof(rtimer.epgTitle)); rtimer.epgTitle[sizeof(rtimer.epgTitle) - 1] = 0; diff --git a/src/nhttpd/tuxboxapi/controlapi.cpp b/src/nhttpd/tuxboxapi/controlapi.cpp index e991785dc..fc4b7d348 100644 --- a/src/nhttpd/tuxboxapi/controlapi.cpp +++ b/src/nhttpd/tuxboxapi/controlapi.cpp @@ -2720,7 +2720,7 @@ void CControlAPI::SendTimers(CyhookHandler *hh) timer_item += hh->outObject("audio", audio, true); timer_item += hh->outPair("recording_dir", timer->recordingDir, true); - timer_item += hh->outPair("epg_id", string_printf("%d", (int)timer->epgID), false); + timer_item += hh->outPair("epg_id", string_printf(PRINTF_CHANNEL_ID_TYPE_NO_LEADING_ZEROS, timer->epgID), false); } break;