urho3d/urho3d

Multiple non-void functions potentially without a return

SirNate0 opened this issue · 0 comments

Getting multiple control reaches end of non-void function in several places, for example
bool Texture2D::GetData(unsigned level, void* dest) const, where there is no return statement when the GAPI is not one of GAPI_OPENGL, GAPI_D3D9, GAPI_D3D11.

I believe they were introduced with #2885.

This is the first time I've seen those changes, so I suppose it's possible the compiler is incorrect, and the function can never not-return one of the options, but I haven't looked into it to see if this is the case. It's probably best to just add return false at the end.