d3dretrace: Try to workaround bug in d3d10's debug layer.

If there's many more of these, then we might need to turn off the debug
layer by default, like we do for D3D9.