diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/main.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -20,6 +20,7 @@ #include <SDL.h> #include <SDL_ttf.h> #include <stdlib.h> +#include <time.h> #include "defs.h" #include "dirs.h" #include "main-menu.h" @@ -31,6 +32,8 @@ static SDL_Renderer *_db_renderer; static int _db_init(void) { + srand(time(NULL)); + if (SDL_Init(SDL_INIT_VIDEO) < 0) { db_err("Failed to initialize SDL (%s)", SDL_GetError()); return -1; |