mirror of
https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git
synced 2025-07-18 19:29:09 +00:00
Plug some simple leaks detected during startup
This commit is contained in:
@ -269,10 +269,13 @@ void pfSecurePreloader::PreloadNextFile()
|
||||
|
||||
void pfSecurePreloader::Init()
|
||||
{
|
||||
RegisterAs(kSecurePreloader_KEY);
|
||||
if (!fInstance)
|
||||
fInstance = new pfSecurePreloader;
|
||||
|
||||
fInstance->RegisterAs(kSecurePreloader_KEY);
|
||||
// TODO: If we're going to support reconnects, then let's do it right.
|
||||
// Later...
|
||||
//plgDispatch::Dispatch()->RegisterForExactType(plNetCommAuthConnectedMsg::Index(), GetKey());
|
||||
//plgDispatch::Dispatch()->RegisterForExactType(plNetCommAuthConnectedMsg::Index(), fInstance->GetKey());
|
||||
}
|
||||
|
||||
void pfSecurePreloader::Start()
|
||||
@ -431,10 +434,3 @@ void pfSecurePreloader::FilePreloaded(const wchar_t* file, hsStream* stream)
|
||||
// Continue down the warpath
|
||||
PreloadNextFile();
|
||||
}
|
||||
|
||||
pfSecurePreloader* pfSecurePreloader::GetInstance()
|
||||
{
|
||||
if (!fInstance)
|
||||
fInstance = new pfSecurePreloader;
|
||||
return fInstance;
|
||||
}
|
||||
|
@ -90,7 +90,7 @@ public:
|
||||
|
||||
plOperationProgress* GetProgressBar() { return fProgress; }
|
||||
|
||||
static pfSecurePreloader* GetInstance();
|
||||
static pfSecurePreloader* GetInstance() { return fInstance; }
|
||||
static void SetInstance(pfSecurePreloader* instance) { fInstance = instance; }
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user