Skip to content

Commit dff500e

Browse files
committed
Fixed lengthy startup problems introduced in 0.8.0
1 parent 195904c commit dff500e

File tree

3 files changed

+35
-21
lines changed

3 files changed

+35
-21
lines changed

UnX/DLL_VERSION.H

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
#define UNX_MAJOR 0
55
#define UNX_MINOR 8
6-
#define UNX_BUILD 0
6+
#define UNX_BUILD 1
77
#define UNX_REV 0
88

99

UnX/dllmain.cpp

+34-20
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,40 @@ DllThread (LPVOID user)
106106
unx::TimingFix::Init ();
107107

108108
unx::WindowManager::Init ();
109+
110+
CreateThread (
111+
nullptr, 0,
112+
[](LPVOID user)->
113+
DWORD
114+
{
115+
SK_UpdateSoftware_pfn SK_UpdateSoftware =
116+
(SK_UpdateSoftware_pfn)
117+
GetProcAddress ( hInjectorDLL,
118+
"SK_UpdateSoftware" );
119+
120+
SK_FetchVersionInfo_pfn SK_FetchVersionInfo =
121+
(SK_FetchVersionInfo_pfn)
122+
GetProcAddress ( hInjectorDLL,
123+
"SK_FetchVersionInfo" );
124+
125+
if (! wcsstr (injector_name.c_str (), L"SpecialK")) {
126+
if ( SK_FetchVersionInfo != nullptr &&
127+
SK_UpdateSoftware != nullptr ) {
128+
if (SK_FetchVersionInfo (L"UnX")) {
129+
SK_UpdateSoftware (L"UnX");
130+
}
131+
}
132+
}
133+
134+
CloseHandle (GetCurrentThread ());
135+
136+
return 0;
137+
},
138+
139+
nullptr,
140+
0x00,
141+
nullptr
142+
);
109143
}
110144

111145
return 0;
@@ -125,26 +159,6 @@ SKPlugIn_Init (HMODULE hModSpecialK)
125159

126160
hInjectorDLL = hModSpecialK;
127161

128-
129-
SK_UpdateSoftware_pfn SK_UpdateSoftware =
130-
(SK_UpdateSoftware_pfn)
131-
GetProcAddress ( hInjectorDLL,
132-
"SK_UpdateSoftware" );
133-
134-
SK_FetchVersionInfo_pfn SK_FetchVersionInfo =
135-
(SK_FetchVersionInfo_pfn)
136-
GetProcAddress ( hInjectorDLL,
137-
"SK_FetchVersionInfo" );
138-
139-
if (! wcsstr (injector_name.c_str (), L"SpecialK")) {
140-
if ( SK_FetchVersionInfo != nullptr &&
141-
SK_UpdateSoftware != nullptr ) {
142-
if (SK_FetchVersionInfo (L"UnX")) {
143-
SK_UpdateSoftware (L"UnX");
144-
}
145-
}
146-
}
147-
148162
DllThread (nullptr);
149163

150164
return TRUE;

version.ini

150 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)