Skip to content

Commit cc90226

Browse files
committed
use auto* for pointers
1 parent 486aa59 commit cc90226

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

Client/multiplayer_sa/CMultiplayerSA_DeviceSelection.cpp

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,9 @@ std::map<std::string, std::string, std::less<>> GetFriendlyMonitorNamesForDevice
2020
if (!user32Lib)
2121
return monitorNames;
2222

23-
auto getDisplayConfigBufferSizes = (decltype(GetDisplayConfigBufferSizes)*)GetProcAddress(user32Lib, "GetDisplayConfigBufferSizes");
24-
auto queryDisplayConfig = (decltype(QueryDisplayConfig)*)GetProcAddress(user32Lib, "QueryDisplayConfig");
25-
auto displayConfigGetDeviceInfo = (decltype(DisplayConfigGetDeviceInfo)*)GetProcAddress(user32Lib, "DisplayConfigGetDeviceInfo");
23+
auto* getDisplayConfigBufferSizes = (decltype(GetDisplayConfigBufferSizes)*)GetProcAddress(user32Lib, "GetDisplayConfigBufferSizes");
24+
auto* queryDisplayConfig = (decltype(QueryDisplayConfig)*)GetProcAddress(user32Lib, "QueryDisplayConfig");
25+
auto* displayConfigGetDeviceInfo = (decltype(DisplayConfigGetDeviceInfo)*)GetProcAddress(user32Lib, "DisplayConfigGetDeviceInfo");
2626
if (!getDisplayConfigBufferSizes || !queryDisplayConfig || !displayConfigGetDeviceInfo)
2727
{
2828
FreeLibrary(user32Lib);
@@ -92,12 +92,12 @@ struct RwSubSystemInfo
9292
using rwDeviceSystemRequest = RwSubSystemInfo*(__cdecl*)(RwDevice* device, std::int32_t requestId, RwSubSystemInfo* pOut, void* pInOut, std::int32_t numIn);
9393
static RwSubSystemInfo* RwEngineGetSubSystemInfo_Hooked(RwSubSystemInfo* subSystemInfo, std::int32_t subSystemIndex)
9494
{
95-
auto rwGlobals = *(RwGlobals**)(0xC97B24);
96-
auto rwDeviceSystemRequestFunc = (rwDeviceSystemRequest)(FUNC_rwDeviceSystemRequest);
95+
auto* rwGlobals = *(RwGlobals**)(0xC97B24);
96+
auto* rwDeviceSystemRequestFunc = (rwDeviceSystemRequest)(FUNC_rwDeviceSystemRequest);
9797
if (!rwDeviceSystemRequestFunc(&rwGlobals->dOpenDevice, 14, subSystemInfo, nullptr, subSystemIndex))
9898
return nullptr;
9999

100-
auto pDxDevice = *(IDirect3D9**)0xC97C20;
100+
auto* pDxDevice = *(IDirect3D9**)0xC97C20;
101101
if (!pDxDevice)
102102
return subSystemInfo;
103103

@@ -124,7 +124,7 @@ static RwSubSystemInfo* RwEngineGetSubSystemInfo_Hooked(RwSubSystemInfo* subSyst
124124
#define FUNC_DialogFunc 0x745E50
125125
INT_PTR CALLBACK CustomDlgProc(HWND window, UINT msg, WPARAM wParam, LPARAM lParam)
126126
{
127-
auto orgDialogFunc = (DLGPROC)FUNC_DialogFunc;
127+
auto* orgDialogFunc = (DLGPROC)FUNC_DialogFunc;
128128
if (msg != WM_INITDIALOG)
129129
return orgDialogFunc(window, msg, wParam, lParam);
130130

0 commit comments

Comments
 (0)