aboutsummaryrefslogtreecommitdiff
path: root/core/io/file_access_pack.cpp
diff options
context:
space:
mode:
authorRémi Verschelde2018-03-20 12:50:19 +0100
committerGitHub2018-03-20 12:50:19 +0100
commitb49ca9486cfae32a9d795ceca52b923820751879 (patch)
treef9ffb22316d64590c46fd1f4f41ff295993b4398 /core/io/file_access_pack.cpp
parent6066b236aac2aa7896f6212cc29874e359e1b74e (diff)
parent536611704a2be026682ce3d6c7454b97122d341e (diff)
downloadgodot-b49ca9486cfae32a9d795ceca52b923820751879.tar.gz
godot-b49ca9486cfae32a9d795ceca52b923820751879.tar.zst
godot-b49ca9486cfae32a9d795ceca52b923820751879.zip
Diffstat (limited to 'core/io/file_access_pack.cpp')
-rw-r--r--core/io/file_access_pack.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/core/io/file_access_pack.cpp b/core/io/file_access_pack.cpp
index 1a16d0f61..efb4c7a07 100644
--- a/core/io/file_access_pack.cpp
+++ b/core/io/file_access_pack.cpp
@@ -88,7 +88,11 @@ void PackedData::add_path(const String &pkg_path, const String &path, uint64_t o
}
}
}
- cd->files.insert(path.get_file());
+ String filename = path.get_file();
+ // Don't add as a file if the path points to a directoryy
+ if (!filename.empty()) {
+ cd->files.insert(filename);
+ }
}
}