diff --git a/CONTRIBUTORS b/CONTRIBUTORS index cafd0f0c..01f72bae 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -2537,6 +2537,7 @@ Markus Ehrnsperger Make.config for reporting a bug in error handling when loading a plugin for reporting a possible crash in cIndexFile::GetClosestIFrame() + for reporting a missing 'const' in cTimers::GetTimerForEvent() Werner Färber for reporting a bug in handling the cPluginManager::Active() result when pressing diff --git a/HISTORY b/HISTORY index d50579e9..abfc26f8 100644 --- a/HISTORY +++ b/HISTORY @@ -9780,7 +9780,7 @@ Video Disk Recorder Revision History out by Onur Sentürk). - Official release. -2022-11-19: +2022-11-20: - Added UPDATE-2.6.0, which was missing in the official 2.6.0 release. - Fixed unexpected calls of the '-r' script when a recording is interrupted and @@ -9799,3 +9799,4 @@ Video Disk Recorder Revision History - Removed some unnecessary locks from SVDRPClientHandler. - Fixed a possible deadlock in case two SVDRP clients send each other POLL commands at the same time. +- Added a missing 'const' to cTimers::GetTimerForEvent() (reported by Markus Ehrnsperger). diff --git a/timers.c b/timers.c index 57aa349b..1f336280 100644 --- a/timers.c +++ b/timers.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: timers.c 5.17 2021/05/03 14:06:12 kls Exp $ + * $Id: timers.c 5.18 2022/11/20 10:57:31 kls Exp $ */ #include "timers.h" @@ -1131,7 +1131,7 @@ const cTimer *cTimers::GetMatch(const cEvent *Event, eTimerMatch *Match) const return t; } -const cTimer *cTimers::GetTimerForEvent(const cEvent *Event, eTimerFlags Flags) +const cTimer *cTimers::GetTimerForEvent(const cEvent *Event, eTimerFlags Flags) const { if (Event && Event->HasTimer()) { for (const cTimer *ti = First(); ti; ti = Next(ti)) { diff --git a/timers.h b/timers.h index 9d40992f..bb4b96fc 100644 --- a/timers.h +++ b/timers.h @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: timers.h 5.8 2021/04/20 13:22:37 kls Exp $ + * $Id: timers.h 5.9 2022/11/20 10:57:31 kls Exp $ */ #ifndef __TIMERS_H @@ -194,7 +194,7 @@ public: cTimer *GetMatch(time_t t) { return const_cast(static_cast(this)->GetMatch(t)); }; const cTimer *GetMatch(const cEvent *Event, eTimerMatch *Match = NULL) const; cTimer *GetMatch(const cEvent *Event, eTimerMatch *Match = NULL) { return const_cast(static_cast(this)->GetMatch(Event, Match)); } - const cTimer *GetTimerForEvent(const cEvent *Event, eTimerFlags Flags = tfNone); + const cTimer *GetTimerForEvent(const cEvent *Event, eTimerFlags Flags = tfNone) const; int GetMaxPriority(void) const; ///< Returns the maximum priority of all local timers that are currently recording. ///< If there is no local timer currently recording, -1 is returned.