diff --git a/modules/juce_core/native/juce_win32_SystemStats.cpp b/modules/juce_core/native/juce_win32_SystemStats.cpp index cec8a2262d..9e47416838 100644 --- a/modules/juce_core/native/juce_win32_SystemStats.cpp +++ b/modules/juce_core/native/juce_win32_SystemStats.cpp @@ -114,7 +114,7 @@ SystemStats::CPUFlags::CPUFlags() #endif SYSTEM_INFO systemInfo; - GetSystemInfo (&systemInfo); + GetNativeSystemInfo (&systemInfo); numCpus = (int) systemInfo.dwNumberOfProcessors; } @@ -344,7 +344,7 @@ bool Time::setSystemTimeToThisTime() const int SystemStats::getPageSize() { SYSTEM_INFO systemInfo; - GetSystemInfo (&systemInfo); + GetNativeSystemInfo (&systemInfo); return (int) systemInfo.dwPageSize; } diff --git a/modules/juce_core/network/juce_URL.cpp b/modules/juce_core/network/juce_URL.cpp index 90444150ce..ff5a4c3e47 100644 --- a/modules/juce_core/network/juce_URL.cpp +++ b/modules/juce_core/network/juce_URL.cpp @@ -241,9 +241,9 @@ String URL::getDomain() const const int end1 = url.indexOfChar (start, '/'); const int end2 = url.indexOfChar (start, ':'); - const int end = (end1 < 0 || end2 < 0) ? jmax (end1, end2) - : jmin (end1, end2); - + const int end = (end1 < 0 && end2 < 0) ? std::numeric_limits::max() + : ((end1 < 0 || end2 < 0) ? jmax (end1, end2) + : jmin (end1, end2)); return url.substring (start, end); } diff --git a/modules/juce_video/native/juce_win32_DirectShowComponent.cpp b/modules/juce_video/native/juce_win32_DirectShowComponent.cpp index 69c0bce74e..bdc183d291 100644 --- a/modules/juce_video/native/juce_win32_DirectShowComponent.cpp +++ b/modules/juce_video/native/juce_win32_DirectShowComponent.cpp @@ -226,12 +226,6 @@ public: CoUninitialize(); } - //====================================================================== - HWND getNativeWindowHandle() const - { - return nativeWindow != nullptr ? nativeWindow->getHandle() : 0; - } - //====================================================================== void updateWindowPosition (const Rectangle& newBounds) { @@ -537,8 +531,6 @@ private: if (c != nullptr) { - jassert (c->getNativeWindowHandle() == hwnd); - switch (msg) { case WM_ERASEBKGND: return 1;