Browse Source

php : FileSystem.fullPath() return null and not false when fails (patch by Ярослав Сиваков)

Franco Ponticelli 14 years ago
parent
commit
807f47251c
1 changed files with 5 additions and 1 deletions
  1. 5 1
      std/php/FileSystem.hx

+ 5 - 1
std/php/FileSystem.hx

@@ -74,7 +74,11 @@ class FileSystem {
 	}
 	}
 
 
 	public static inline function fullPath( relpath : String ) : String {
 	public static inline function fullPath( relpath : String ) : String {
-		return untyped __call__("realpath", relpath);
+		var p = untyped __call__("realpath", relpath);
+		if (untyped __physeq__(p, false))
+			return null;
+		else
+			return p;s
 	}
 	}
 
 
 	public static function kind( path : String ) : FileKind {
 	public static function kind( path : String ) : FileKind {