Skip to content

Commit

Permalink
Static analysis fix: uninitialized value.
Browse files Browse the repository at this point in the history
(A false positive: clang doesn't know SDL_SetError() always returns -1.)
  • Loading branch information
icculus committed Mar 20, 2014
1 parent a25bd63 commit 93ba5bd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/render/SDL_render.c
Expand Up @@ -350,7 +350,7 @@ SDL_GetRendererOutputSize(SDL_Renderer * renderer, int *w, int *h)
SDL_GetWindowSize(renderer->window, w, h);
return 0;
} else {
/* This should never happen */
SDL_assert(0 && "This should never happen");
return SDL_SetError("Renderer doesn't support querying output size");
}
}
Expand Down Expand Up @@ -1117,7 +1117,7 @@ SDL_GetRenderTarget(SDL_Renderer *renderer)
static int
UpdateLogicalSize(SDL_Renderer *renderer)
{
int w, h;
int w = 1, h = 1;
float want_aspect;
float real_aspect;
float scale;
Expand Down

0 comments on commit 93ba5bd

Please sign in to comment.