summaryrefslogtreecommitdiff
path: root/drivers/unix/file_access_unix.cpp
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2017-09-17 22:40:54 +0200
committerGitHub <noreply@github.com>2017-09-17 22:40:54 +0200
commit73b8e5acab7e389d7ce8cfb48d533ba74cd86133 (patch)
tree46c6a9cbc85eba19818fa5b9f8ef3c2a6615c194 /drivers/unix/file_access_unix.cpp
parent65ef19abe3cb95df72f5256b17ec6667ed26cf6d (diff)
parent3528b1e571dee24917b0141232f135e29bf088ba (diff)
Merge pull request #11362 from marcelofg55/fix_x11_export
Fix x11 exported executables not getting the +x flag
Diffstat (limited to 'drivers/unix/file_access_unix.cpp')
-rw-r--r--drivers/unix/file_access_unix.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/unix/file_access_unix.cpp b/drivers/unix/file_access_unix.cpp
index 80565c5b02..e19bc738cb 100644
--- a/drivers/unix/file_access_unix.cpp
+++ b/drivers/unix/file_access_unix.cpp
@@ -274,6 +274,15 @@ uint64_t FileAccessUnix::_get_modified_time(const String &p_file) {
};
}
+Error FileAccessUnix::_chmod(const String &p_path, int p_mod) {
+ int err = chmod(p_path.utf8().get_data(), p_mod);
+ if (!err) {
+ return OK;
+ }
+
+ return FAILED;
+}
+
FileAccess *FileAccessUnix::create_libc() {
return memnew(FileAccessUnix);