(XDK D3D) Put some guards around invoking function pointers