@@ -83,12 +83,17 @@ { #ifdef OF_PSP int tid; #endif -#if defined(OF_OBJFW_RUNTIME) && !defined(OF_WINDOWS) - /* This does not work on Win32 if ObjFW is built as a DLL */ +#if defined(OF_OBJFW_RUNTIME) && !defined(OF_WINDOWS) && !defined(OF_AMIGAOS4) + /* + * This does not work on Win32 if ObjFW is built as a DLL. + * + * On AmigaOS 4, atexit() calls objc_exit() before our destructors have + * run, but we need to send messages in some destructors. + */ atexit(objc_exit); #endif /* We need deterministic hashes for tests */ of_hash_seed = 0;