summaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/text.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/text.c b/src/text.c
index 3c2c9924..51fee3eb 100644
--- a/src/text.c
+++ b/src/text.c
@@ -622,6 +622,12 @@ Image GenImageFontAtlas(const CharInfo *chars, Rectangle **charRecs, int charsCo
{
Image atlas = { 0 };
+ if (chars == NULL)
+ {
+ TraceLog(LOG_WARNING, "FONT: Provided chars info not valid, returning empty image atlas");
+ return atlas;
+ }
+
*charRecs = NULL;
// In case no chars count provided we suppose default of 95