mirror of
https://git.suyu.dev/suyu/suyu.git
synced 2024-11-05 06:22:45 +01:00
service/time: Add virtual destructors where applicable
Many of these implementations are used to implement a polymorphic interface. While not directly used polymorphically, this prevents virtual destruction from ever becoming an issue.
This commit is contained in:
parent
fd7dc7e03d
commit
0cfd3b94db
3 changed files with 3 additions and 2 deletions
|
@ -16,6 +16,7 @@ namespace Service::Time::Clock {
|
||||||
class SteadyClockCore {
|
class SteadyClockCore {
|
||||||
public:
|
public:
|
||||||
SteadyClockCore() = default;
|
SteadyClockCore() = default;
|
||||||
|
virtual ~SteadyClockCore() = default;
|
||||||
|
|
||||||
const Common::UUID& GetClockSourceId() const {
|
const Common::UUID& GetClockSourceId() const {
|
||||||
return clock_source_id;
|
return clock_source_id;
|
||||||
|
|
|
@ -20,7 +20,7 @@ namespace Service::Time::Clock {
|
||||||
class SystemClockContextUpdateCallback {
|
class SystemClockContextUpdateCallback {
|
||||||
public:
|
public:
|
||||||
SystemClockContextUpdateCallback();
|
SystemClockContextUpdateCallback();
|
||||||
~SystemClockContextUpdateCallback();
|
virtual ~SystemClockContextUpdateCallback();
|
||||||
|
|
||||||
bool NeedUpdate(const SystemClockContext& value) const;
|
bool NeedUpdate(const SystemClockContext& value) const;
|
||||||
|
|
||||||
|
|
|
@ -22,7 +22,7 @@ class SystemClockContextUpdateCallback;
|
||||||
class SystemClockCore {
|
class SystemClockCore {
|
||||||
public:
|
public:
|
||||||
explicit SystemClockCore(SteadyClockCore& steady_clock_core);
|
explicit SystemClockCore(SteadyClockCore& steady_clock_core);
|
||||||
~SystemClockCore();
|
virtual ~SystemClockCore();
|
||||||
|
|
||||||
SteadyClockCore& GetSteadyClockCore() const {
|
SteadyClockCore& GetSteadyClockCore() const {
|
||||||
return steady_clock_core;
|
return steady_clock_core;
|
||||||
|
|
Loading…
Reference in a new issue