selfrando
selfrando copied to clipboard
Selfrando does not play well with delay loading on Windows
The MSVC linker on Windows supports delay loading, where a DLL is only loaded when one of its exports is called for the first time, as opposed to program startup, somewhat similarly to lazy linking on Linux. On Windows, this implementation relies on a helper function called __delayLoadHelper2
which is available in the delayimp
library. However, randomization moves this helper function around, which breaks delay loading.
For now, we just disable delay loading. However, delay loading can significantly reduce startup times, so we should find a way to support it.
Fixed on Win64/Windows 10/MSVC 2015 by commit c0e7a0c10b3cf766b3a341a0faf7efc50a588a9d.