Calling garbage collector initializer at the main function

This commit is contained in:
MarcUs7i 2025-01-29 16:10:13 +01:00
parent 30bf07cc4f
commit 0d89f13f1f

View file

@ -12,6 +12,7 @@
#include <stdio.h> #include <stdio.h>
#include <string.h> #include <string.h>
#include <stdlib.h> #include <stdlib.h>
#include <gc.h>
#include "ms_game.h" #include "ms_game.h"
#include "ms_visualizer.h" #include "ms_visualizer.h"
@ -38,6 +39,7 @@ void ui_branch(GameMode mode);
*/ */
int main(int argc, char *argv[]) int main(int argc, char *argv[])
{ {
GC_INIT();
GameMode mode = BEGINNER; GameMode mode = BEGINNER;
/* can be surrounded with a loop to restart the game in a different mode */ /* can be surrounded with a loop to restart the game in a different mode */
mode = ui_prompt_for_mode(); mode = ui_prompt_for_mode();