From 939bf1c4d8c3d35f5d9e99efa80140b4a7873565 Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Mon, 3 Dec 2018 02:06:17 -0500 Subject: [PATCH] render: fix some static analysis warnings. --- src/render/SDL_render.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/render/SDL_render.c b/src/render/SDL_render.c index 7f2b47c22..2d087258e 100644 --- a/src/render/SDL_render.c +++ b/src/render/SDL_render.c @@ -2658,6 +2658,7 @@ SDL_RenderFillRect(SDL_Renderer * renderer, const SDL_Rect * rect) frect.h = (float) rect->h; } else { SDL_Rect r; + SDL_zero(r); SDL_RenderGetViewport(renderer, &r); frect.x = 0.0f; frect.y = 0.0f; @@ -2677,6 +2678,7 @@ SDL_RenderFillRectF(SDL_Renderer * renderer, const SDL_FRect * rect) /* If 'rect' == NULL, then outline the whole surface */ if (!rect) { SDL_Rect r; + SDL_zero(r); SDL_RenderGetViewport(renderer, &r); frect.x = 0.0f; frect.y = 0.0f;