diff options
author | Max Horn | 2006-04-26 08:13:25 +0000 |
---|---|---|
committer | Max Horn | 2006-04-26 08:13:25 +0000 |
commit | f42bb14ea3f0c4e4801a026d6ff9cd881d0999df (patch) | |
tree | 1bbe3d28e0393daae113966fd331736643e3eb00 | |
parent | d5224d87bbdc89101801228236e6925995669bd2 (diff) | |
download | scummvm-rg350-f42bb14ea3f0c4e4801a026d6ff9cd881d0999df.tar.gz scummvm-rg350-f42bb14ea3f0c4e4801a026d6ff9cd881d0999df.tar.bz2 scummvm-rg350-f42bb14ea3f0c4e4801a026d6ff9cd881d0999df.zip |
Commited *correct* File::exists reimplementation (compared to my incomplete previous commit. Aargh)
svn-id: r22170
-rw-r--r-- | common/file.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/common/file.cpp b/common/file.cpp index 29c3b332da..90acdb45d3 100644 --- a/common/file.cpp +++ b/common/file.cpp @@ -263,9 +263,8 @@ bool File::open(const String &filename, AccessMode mode, const char *directory) } bool File::exists(const String &filename) { - // FIXME: Ugly ugly hack! - File tmp; - return tmp.open(filename, kFileReadMode); + FilesystemNode file(filename); + return (file.isValid() && !file.isDirectory()); } void File::close() { |