dxerr9.h and DXGetErrorString9 exist if and only if jou have an old DirectX SDK, in other cases you have dxerr.h and DXGetErrorString
But for mingw, I'm not sure...
If you think that this change is not necessary, I'll withdraw it.