From 883998736b18006def07e7bcbbf9d1bcfac97bf6 Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Wed, 9 Mar 2011 14:47:37 -0800 Subject: [PATCH] Make the globals static so they're initialized to zero. --- test/testgesture.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/test/testgesture.c b/test/testgesture.c index c103e43b3..bf025c420 100644 --- a/test/testgesture.c +++ b/test/testgesture.c @@ -45,12 +45,12 @@ #define VERBOSE SDL_FALSE -SDL_Window *window; -SDL_Event events[EVENT_BUF_SIZE]; -int eventWrite; +static SDL_Window *window; +static SDL_Event events[EVENT_BUF_SIZE]; +static int eventWrite; -int colors[7] = {0xFF,0xFF00,0xFF0000,0xFFFF00,0x00FFFF,0xFF00FF,0xFFFFFF}; +static int colors[7] = {0xFF,0xFF00,0xFF0000,0xFFFF00,0x00FFFF,0xFF00FF,0xFFFFFF}; typedef struct { float x,y; @@ -61,7 +61,7 @@ typedef struct { Point p; } Knob; -Knob knob; +static Knob knob; void handler (int sig) {