Browse Source

small filesystem code cleanup

Sasha Szpakowski 7 months ago
parent
commit
8e98711096

+ 0 - 1
src/modules/event/sdl/Event.cpp

@@ -21,7 +21,6 @@
 #include "Event.h"
 
 #include "common/int.h"
-#include "filesystem/NativeFile.h"
 #include "filesystem/Filesystem.h"
 #include "keyboard/sdl/Keyboard.h"
 #include "joystick/JoystickModule.h"

+ 0 - 2
src/modules/filesystem/Filesystem.h

@@ -58,8 +58,6 @@ namespace love
 namespace filesystem
 {
 
-class NativeFile;
-
 class Filesystem : public Module
 {
 public:

+ 3 - 1
src/modules/filesystem/physfs/Filesystem.cpp

@@ -690,7 +690,9 @@ std::string Filesystem::getFullCommonPath(CommonPath path)
 
 #endif
 
-	fullPaths[path] = canonicalizeRealPath(fullPaths[path].c_str());
+	if (!fullPaths[path].empty())
+		fullPaths[path] = canonicalizeRealPath(fullPaths[path].c_str());
+
 	return fullPaths[path];
 }