Commit 39690a047897e470b68b51732463dc07a786cf5e

Sylvain Becker 2020-05-15T21:33:47

Fix static analysis warning in SDL_render.c

1
2
3
4
5
6
7
8
9
10
11
12
13
14
diff --git a/src/render/SDL_render.c b/src/render/SDL_render.c
index ce83553..b506556 100644
--- a/src/render/SDL_render.c
+++ b/src/render/SDL_render.c
@@ -1745,7 +1745,8 @@ SDL_LockTextureToSurface(SDL_Texture *texture, const SDL_Rect *rect,
 {
     SDL_Rect real_rect;
     void *pixels = NULL;
-    int pitch, ret;
+    int pitch = 0; /* fix static analysis */
+    int ret;
 
     if (texture == NULL || surface == NULL) {
         return -1;