Corrected issue on style loading

This commit is contained in:
Ray
2017-05-10 00:50:21 +02:00
parent 85f34d0b7f
commit b941f305a0

View File

@ -1424,6 +1424,8 @@ RAYGUIDEF void LoadGuiStyle(const char *fileName)
FILE *styleFile = fopen(fileName, "rt"); FILE *styleFile = fopen(fileName, "rt");
if (styleFile != NULL)
{
while (!feof(styleFile)) while (!feof(styleFile))
{ {
fscanf(styleFile, "%s %i\n", styleProp[counter].id, &styleProp[counter].value); fscanf(styleFile, "%s %i\n", styleProp[counter].id, &styleProp[counter].value);
@ -1443,6 +1445,7 @@ RAYGUIDEF void LoadGuiStyle(const char *fileName)
} }
} }
} }
}
RAYGUI_FREE(styleProp); RAYGUI_FREE(styleProp);
} }