summaryrefslogtreecommitdiff
path: root/apt-pkg
diff options
context:
space:
mode:
authorSam Bingner <sam@bingner.com>2018-09-30 22:50:02 -1000
committerSam Bingner <sam@bingner.com>2019-08-18 12:07:59 -1000
commit23dbbe24511b0a5db2ef47a3846cd59b7fb9a106 (patch)
tree31be3bd3eed2c19fac852992e56d5d8a477ae57b /apt-pkg
parent253a7b37f6dccf97dc12425f01dabe05f29bbb73 (diff)
Use access instead of faccessat for iOS5 compatibility
Diffstat (limited to 'apt-pkg')
-rw-r--r--apt-pkg/contrib/fileutl.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/apt-pkg/contrib/fileutl.cc b/apt-pkg/contrib/fileutl.cc
index 73e738959..7e80e251c 100644
--- a/apt-pkg/contrib/fileutl.cc
+++ b/apt-pkg/contrib/fileutl.cc
@@ -3066,7 +3066,7 @@ static std::string APT_NONNULL(1) GetTempDirEnv(char const * const env) /*{{{*/
stat(tmpdir, &st) != 0 || (st.st_mode & S_IFDIR) == 0) // exists and is directory
tmpdir = "/tmp";
else if (geteuid() != 0 && // root can do everything anyway
- faccessat(AT_FDCWD, tmpdir, R_OK | W_OK | X_OK, AT_EACCESS) != 0) // current user has rwx access to directory
+ access(tmpdir, R_OK | W_OK | X_OK) != 0) // current user has rwx access to directory
tmpdir = "/tmp";
return string(tmpdir);