Probably calling ChangeDisplaySettingsExW(NULL, NULL, NULL, 0, NULL);
on DLL_PROCESS_DETACH in user32 would do the trick, but it's not clear
if that's the right thing to do, especially if an exiting process is not
the one who has changed the resolution, or the resolution has been changed
on behalf of other process.
Probably calling ChangeDisplaySe ttingsExW( NULL, NULL, NULL, 0, NULL);
on DLL_PROCESS_DETACH in user32 would do the trick, but it's not clear
if that's the right thing to do, especially if an exiting process is not
the one who has changed the resolution, or the resolution has been changed
on behalf of other process.