mirror of https://github.com/encounter/SDL.git
avoid NullPointer in SDL_GetRenderTarget
This commit is contained in:
parent
01b14e14e6
commit
0adb67017b
|
@ -2263,6 +2263,8 @@ SDL_SetRenderTarget(SDL_Renderer *renderer, SDL_Texture *texture)
|
|||
SDL_Texture *
|
||||
SDL_GetRenderTarget(SDL_Renderer *renderer)
|
||||
{
|
||||
CHECK_RENDERER_MAGIC(renderer, NULL);
|
||||
|
||||
return renderer->target;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue