summaryrefslogtreecommitdiff
path: root/Source/Core
diff options
context:
space:
mode:
authorShawn Hoffman <godisgovernment@gmail.com>2020-08-17 17:32:58 -0700
committerShawn Hoffman <godisgovernment@gmail.com>2020-08-23 13:57:05 -0700
commitccbc4c2d991cd42dbc2943aebe617d31b2c74a59 (patch)
tree4accb7524298914907ba29640d0acddda6da4f1c /Source/Core
parent3ee4c53d652c52f3733194534a9538730d1806e4 (diff)
fix possible dangling shared_ptr ptr in ios
Diffstat (limited to 'Source/Core')
-rw-r--r--Source/Core/Core/IOS/IOS.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/Source/Core/Core/IOS/IOS.cpp b/Source/Core/Core/IOS/IOS.cpp
index ede48baf1b..b5fe88b709 100644
--- a/Source/Core/Core/IOS/IOS.cpp
+++ b/Source/Core/Core/IOS/IOS.cpp
@@ -824,7 +824,8 @@ void Init()
if (!s_ios)
return;
- auto device = static_cast<Device::SDIOSlot0*>(s_ios->GetDeviceByName("/dev/sdio/slot0").get());
+ auto sdio_slot0 = s_ios->GetDeviceByName("/dev/sdio/slot0");
+ auto device = static_cast<Device::SDIOSlot0*>(sdio_slot0.get());
if (device)
device->EventNotify();
});