diff --git a/src/main.cpp b/src/main.cpp index 9a33ea9..e869370 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -15,7 +15,8 @@ int main(int argc, char **argv) { // Initialise the Graphics & Video subsystem GRRLIB_Init(); - global_data->myFont =GRRLIB_LoadTTF(FreeMonoBold_ttf, FreeMonoBold_ttf_size); + GRRLIB_ttfFont* myFont=GRRLIB_LoadTTF(FreeMonoBold_ttf, FreeMonoBold_ttf_size); + global_data->myFont=myFont; // Initialise the Controllers Ctrl_Init(); @@ -37,7 +38,7 @@ int main(int argc, char **argv) { GRRLIB_Render(); // Render the frame buffer to the TV } - GRRLIB_FreeTTF(global_data->myFont); + GRRLIB_FreeTTF(myFont); free(global_data); GRRLIB_Exit(); // Be a good boy, clear the memory allocated by GRRLIB