diff options
author | bunnei <bunneidev@gmail.com> | 2019-11-26 21:48:56 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-11-26 21:48:56 -0500 |
commit | ec0ce96c568b2b610c5218efd7faa5d9a19350f8 (patch) | |
tree | 61b5133e3cc6a9edf3b45c5fe6604493689f6769 /src/core/hardware_interrupt_manager.h | |
parent | 31daaa79119a2a863adf4216c7ce64495dc71344 (diff) |
core_timing: Use better reference tracking for EventType. (#3159)
* core_timing: Use better reference tracking for EventType.
- Moves ownership of the event to the caller, ensuring we don't fire events for destroyed objects.
- Removes need for unique names - we won't be using this for save states anyways.
Diffstat (limited to 'src/core/hardware_interrupt_manager.h')
-rw-r--r-- | src/core/hardware_interrupt_manager.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/core/hardware_interrupt_manager.h b/src/core/hardware_interrupt_manager.h index 494db883ad..5fa306ae0a 100644 --- a/src/core/hardware_interrupt_manager.h +++ b/src/core/hardware_interrupt_manager.h @@ -4,6 +4,8 @@ #pragma once +#include <memory> + #include "common/common_types.h" namespace Core { @@ -25,7 +27,7 @@ public: private: Core::System& system; - Core::Timing::EventType* gpu_interrupt_event{}; + std::shared_ptr<Core::Timing::EventType> gpu_interrupt_event; }; } // namespace Core::Hardware |