aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/text.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/text.c b/src/text.c
index b1f786b7..464c0f02 100644
--- a/src/text.c
+++ b/src/text.c
@@ -1406,6 +1406,10 @@ static Font LoadBMFont(const char *fileName)
char *lastSlash = NULL;
lastSlash = strrchr(fileName, '/');
+ if (lastSlash == NULL)
+ {
+ lastSlash = strrchr(fileName, '\\');
+ }
// NOTE: We need some extra space to avoid memory corruption on next allocations!
texPath = malloc(strlen(fileName) - strlen(lastSlash) + strlen(texFileName) + 4);