From 3a12af88b779b667ace2dc594f0e8ec48b83b58a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lars=20N=C3=A6sbye=20Christensen?= Date: Fri, 9 Feb 2024 02:11:50 +0100 Subject: llplugin: BOOL (int) to real bool --- indra/llplugin/llpluginclassmedia.cpp | 2 +- indra/llplugin/llpluginsharedmemory.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'indra/llplugin') diff --git a/indra/llplugin/llpluginclassmedia.cpp b/indra/llplugin/llpluginclassmedia.cpp index 3e72710366..d45600763d 100644 --- a/indra/llplugin/llpluginclassmedia.cpp +++ b/indra/llplugin/llpluginclassmedia.cpp @@ -35,7 +35,7 @@ extern LLControlGroup gSavedSettings; #if LL_DARWIN -extern BOOL gHiDPISupport; +extern bool gHiDPISupport; #endif static int LOW_PRIORITY_TEXTURE_SIZE_DEFAULT = 256; diff --git a/indra/llplugin/llpluginsharedmemory.cpp b/indra/llplugin/llpluginsharedmemory.cpp index 63ff5085c6..3fc9cbd973 100644 --- a/indra/llplugin/llpluginsharedmemory.cpp +++ b/indra/llplugin/llpluginsharedmemory.cpp @@ -478,7 +478,7 @@ bool LLPluginSharedMemory::attach(const std::string &name, size_t size) mImpl->mMapFile = OpenFileMappingA( FILE_MAP_ALL_ACCESS, // read/write access - FALSE, // do not inherit the name + false, // do not inherit the name mName.c_str()); // name of mapping object if(mImpl->mMapFile == NULL) -- cgit v1.2.3 From 0a42ed6cc5e70f8cb78dd770aa8edcbae8ab2f02 Mon Sep 17 00:00:00 2001 From: Ansariel Date: Mon, 19 Feb 2024 19:03:46 +0100 Subject: Remove orphaned 32bit Windows code from slplugin.cpp --- indra/llplugin/slplugin/slplugin.cpp | 27 ++++----------------------- 1 file changed, 4 insertions(+), 23 deletions(-) (limited to 'indra/llplugin') diff --git a/indra/llplugin/slplugin/slplugin.cpp b/indra/llplugin/slplugin/slplugin.cpp index 5c54705c71..bf5e223181 100644 --- a/indra/llplugin/slplugin/slplugin.cpp +++ b/indra/llplugin/slplugin/slplugin.cpp @@ -88,22 +88,6 @@ LONG WINAPI myWin32ExceptionHandler( struct _EXCEPTION_POINTERS* exception_infop return EXCEPTION_EXECUTE_HANDLER; } -// Taken from : http://blog.kalmbachnet.de/?postid=75 -// The MSVC 2005 CRT forces the call of the default-debugger (normally Dr.Watson) -// even with the other exception handling code. This (terrifying) piece of code -// patches things so that doesn't happen. -LPTOP_LEVEL_EXCEPTION_FILTER WINAPI MyDummySetUnhandledExceptionFilter( - LPTOP_LEVEL_EXCEPTION_FILTER lpTopLevelExceptionFilter ) -{ - return NULL; -} - -BOOL PreventSetUnhandledExceptionFilter() -{ - // remove the scary stuff that also isn't supported on 64 bit Windows - return TRUE; -} - //////////////////////////////////////////////////////////////////////////////// // Hook our exception handler and replace the system one void initExceptionHandler() @@ -112,7 +96,6 @@ void initExceptionHandler() // save old exception handler in case we need to restore it at the end prev_filter = SetUnhandledExceptionFilter( myWin32ExceptionHandler ); - PreventSetUnhandledExceptionFilter(); } bool checkExceptionHandler() @@ -121,18 +104,16 @@ bool checkExceptionHandler() LPTOP_LEVEL_EXCEPTION_FILTER prev_filter; prev_filter = SetUnhandledExceptionFilter(myWin32ExceptionHandler); - PreventSetUnhandledExceptionFilter(); - if (prev_filter != myWin32ExceptionHandler) { LL_WARNS("AppInit") << "Our exception handler (" << (void *)myWin32ExceptionHandler << ") replaced with " << prev_filter << "!" << LL_ENDL; ok = false; } - if (prev_filter == NULL) + if (prev_filter == nullptr) { - ok = FALSE; - if (NULL == myWin32ExceptionHandler) + ok = false; + if (nullptr == myWin32ExceptionHandler) { LL_WARNS("AppInit") << "Exception handler uninitialized." << LL_ENDL; } @@ -245,7 +226,7 @@ int main(int argc, char **argv) F64 elapsed = timer.getElapsedTimeF64(); F64 remaining = plugin->getSleepTime() - elapsed; - if(remaining <= 0.0f) + if(remaining <= 0.0) { // We've already used our full allotment. // LL_INFOS("slplugin") << "elapsed = " << elapsed * 1000.0f << " ms, remaining = " << remaining * 1000.0f << " ms, not sleeping" << LL_ENDL; -- cgit v1.2.3