Skip to content

Only call GetModuleHandle and AddVectoredExceptionHandler when targeting Windows Desktop

Martin Storsjö requested to merge mstorsjo/dav1d:uwp into master

Don't call them when targeting e.g. UWP.

This requires building with a new enough SDK that does have the winapifamily.h header (and that it's included implicitly by regular platform headers); it's been available since the Windows 8.0 SDK (and since mingw-w64 v3.0.0) so it should be safe.

Also rewrite the GetProcAddress call to avoid calling it if GetModuleHandleW(L"kernel32.dll") would return NULL for some reason.

Merge request reports