Don't assert on API parameters

This causes lots of spam in test automation and it's not clear it's useful to developers. If we need this level of validation, we should add a log category for it.
This commit is contained in:
Sam Lantinga
2021-11-10 09:41:43 -08:00
parent fed857787a
commit 6c4b4ee7a6
3 changed files with 0 additions and 6 deletions

View File

@@ -47,14 +47,12 @@ this should probably be removed at some point in the future. --ryan. */
#define SDL_WINDOWRENDERDATA "_SDL_WindowRenderData"
#define CHECK_RENDERER_MAGIC(renderer, retval) \
SDL_assert(renderer && renderer->magic == &renderer_magic); \
if (!renderer || renderer->magic != &renderer_magic) { \
SDL_SetError("Invalid renderer"); \
return retval; \
}
#define CHECK_TEXTURE_MAGIC(texture, retval) \
SDL_assert(texture && texture->magic == &texture_magic); \
if (!texture || texture->magic != &texture_magic) { \
SDL_SetError("Invalid texture"); \
return retval; \