diff --git a/RpcCore/RpcCore.c b/RpcCore/RpcCore.c index 76825f7..53187b3 100644 --- a/RpcCore/RpcCore.c +++ b/RpcCore/RpcCore.c @@ -289,7 +289,7 @@ VOID* __fastcall RpcCoreInit(BOOL bForce) if (GetSystemDirectoryW(RpcRuntimePath,_countof(RpcRuntimePath))==0) goto End; StringCbPrintfW(RpcRuntimePath,sizeof(RpcRuntimePath),L"%s\\rpcrt4.dll",RpcRuntimePath); RuntimVersion=GetModuleVersion(RpcRuntimePath); - for (i = 0; i < sizeof(RPC_CORE_RUNTIME_VERSION); i++) + for (i = 0; i < _countof(RPC_CORE_RUNTIME_VERSION); i++) { if (bForce && ((RuntimVersion & 0xFFFFFFFF00000000) == (RPC_CORE_RUNTIME_VERSION[i] & 0xFFFFFFFF00000000))) {