1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-10 13:00:37 +00:00

Fix x11 exported executables not getting the +x flag

This commit is contained in:
Marcelo Fernandez
2017-09-17 14:40:58 -03:00
parent 574a5714dc
commit 3528b1e571
8 changed files with 43 additions and 4 deletions

View File

@@ -292,7 +292,7 @@ String DirAccess::get_full_path(const String &p_path, AccessType p_access) {
return full;
}
Error DirAccess::copy(String p_from, String p_to) {
Error DirAccess::copy(String p_from, String p_to, int chmod_flags) {
//printf("copy %s -> %s\n",p_from.ascii().get_data(),p_to.ascii().get_data());
Error err;
@@ -329,6 +329,11 @@ Error DirAccess::copy(String p_from, String p_to) {
fdst->store_8(fsrc->get_8());
}
if (err == OK && chmod_flags != -1) {
fdst->close();
err = fdst->_chmod(p_to, chmod_flags);
}
memdelete(fsrc);
memdelete(fdst);