Skip to content
This repository has been archived by the owner on Feb 11, 2021. It is now read-only.

Commit

Permalink
Make the globals static so they're initialized to zero.
Browse files Browse the repository at this point in the history
  • Loading branch information
slouken committed Mar 9, 2011
1 parent ff5e8b6 commit 8839987
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions test/testgesture.c
Expand Up @@ -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;
Expand All @@ -61,7 +61,7 @@ typedef struct {
Point p;
} Knob;

Knob knob;
static Knob knob;

void handler (int sig)
{
Expand Down

0 comments on commit 8839987

Please sign in to comment.