diff src/joystick/bsd/SDL_sysjoystick.c @ 965:b68e551205e9

Fix from Alfred Perlstein
author Sam Lantinga <slouken@libsdl.org>
date Fri, 12 Nov 2004 21:24:46 +0000
parents 18922ae3ee07
children 58538e140e2d
line wrap: on
line diff
--- a/src/joystick/bsd/SDL_sysjoystick.c	Sat Nov 06 08:56:23 2004 +0000
+++ b/src/joystick/bsd/SDL_sysjoystick.c	Fri Nov 12 21:24:46 2004 +0000
@@ -160,6 +160,7 @@
 			SDL_numjoysticks++;
 		} else {
 			free(joynames[nj.index]);
+			joynames[nj.index] = NULL;
 		}
 	}
 	for (i = 0; i < MAX_JOY_JOYS; i++) {