Patch from James H: make the Windows debugging output conditional on