diff --git a/src/filesystem/SDL_filesystem.c b/src/filesystem/SDL_filesystem.c index a29ae38fdda20..4007f40721aae 100644 --- a/src/filesystem/SDL_filesystem.c +++ b/src/filesystem/SDL_filesystem.c @@ -107,6 +107,10 @@ bool SDL_CreateDirectory(const char *path) } SDL_free(parents); + + if (retval) { + SDL_ClearError(); + } } return retval; }