summaryrefslogtreecommitdiff
path: root/Source/Core
diff options
context:
space:
mode:
authorLéo Lam <leo@innovatetechnologi.es>2017-06-10 19:48:45 +0200
committerLéo Lam <leo@innovatetechnologi.es>2017-06-10 20:00:43 +0200
commit91bcd756ffe060319cb858572dbe118657c2ddfd (patch)
treed237b6c7604a55c272379e01c5080e055813af8a /Source/Core
parent3eecf67a2abdc85da596c731f40a20c3ffa847b3 (diff)
Core: Remove useless ShutdownWiiRoot calls
I don't see why we need to call ShutdownWiiRoot on InitializeWiiRoot. Also, atexit? Really? Not only is this unnecessary, it will also cause ShutdownWiiRoot to be called twice in rapid succession for no reason.
Diffstat (limited to 'Source/Core')
-rw-r--r--Source/Core/Core/WiiRoot.cpp12
1 files changed, 0 insertions, 12 deletions
diff --git a/Source/Core/Core/WiiRoot.cpp b/Source/Core/Core/WiiRoot.cpp
index 995e633522..7a2f5104b3 100644
--- a/Source/Core/Core/WiiRoot.cpp
+++ b/Source/Core/Core/WiiRoot.cpp
@@ -16,10 +16,6 @@
#include "Core/Movie.h"
#include "Core/NetPlayClient.h"
-#ifdef _WIN32
-#include <Windows.h>
-#endif
-
namespace Core
{
static std::string s_temp_wii_root;
@@ -56,8 +52,6 @@ static void InitializeDeterministicWiiSaves()
void InitializeWiiRoot(bool use_temporary)
{
- ShutdownWiiRoot();
-
if (use_temporary)
{
s_temp_wii_root = File::CreateTempDir();
@@ -69,12 +63,6 @@ void InitializeWiiRoot(bool use_temporary)
File::CopyDir(File::GetSysDirectory() + WII_USER_DIR, s_temp_wii_root);
WARN_LOG(IOS_FILEIO, "Using temporary directory %s for minimal Wii FS",
s_temp_wii_root.c_str());
- static bool s_registered;
- if (!s_registered)
- {
- s_registered = true;
- atexit(ShutdownWiiRoot);
- }
File::SetUserPath(D_SESSION_WIIROOT_IDX, s_temp_wii_root);
// Generate a SYSCONF with default settings for the temporary Wii NAND.
SysConf sysconf{Common::FromWhichRoot::FROM_SESSION_ROOT};