Running Visual Lint under Windows Vista
Saturday 20th January, 2007
In the FAQ for Visual Lint we state that "We are in the process of testing on Windows Vista, and hope to have a compatible version soon. Please contact us if you have any queries about compatibility with a particular platform."
We've been using Vista routinely now since the release of RC1 back in September, and have had the RTM version running for over a month now. As a result we now have a pretty good idea what changes we need to make to support the new platform, and those are now well underway.
The good news is that Visual Lint seems to work just fine under Vista (we've tested pretty extensively with VS2003 and VS2005), but installation is a little tricky at the moment. Although we are in the process of writing a new installer to work around the issues we've encountered, it is (unfortunately) not yet ready.
So, in the meantime, I'd like to discuss how to get current versions of Visual Lint working under Vista.
The main issue is that if you attempt to install Visual Lint on a Vista system which has Hardware DEP (Data Execution Prevention) enabled, you are likely to see the following message during installation:

Attempting to register the DLL from the command line (note that it must be an admin prompt or UAC will disallow the action) will also fail:

The crash is caused by a conflict between the Vista implementation of Hardware DEP (which is much more aggressive than that provided with WinXP) and the third party solution we use to handle licence keys and provide some level of protection against crackers. The vendor are aware of this issue but do not currently have a solution available.
Fortunately there is a workaround. In order to install the software, you can either:
-
Install using Safe Mode
-
Disable Hardware DEP on regsvr32.exe
Vista by default installs with DEP enabled on "essential Windows processes and services only", so in order to use the second method DEP must be disabled on regsvr32.exe. This can be accomplished from the "Performance Options" property sheet, accessible via System Properties:

Note however that any Visual Studio IDEs you intend to use should also have DEP disabled, as you can see in the screenshot above.
Once this has been done and the system restarted Visual Lint should install and run without issues:

If you identify any other issues with Vista, we'd be very interested to hear them.
