diff --git a/src/env.cpp b/src/env.cpp index 15bc174b1..339274cb2 100644 --- a/src/env.cpp +++ b/src/env.cpp @@ -1421,8 +1421,7 @@ wcstring env_get_runtime_path() { // Check that the path is actually usable. Technically this is guaranteed by the fdo spec but in // practice it is not always the case: see #1828 and #2222. - int mode = R_OK | W_OK | X_OK; - if (dir != nullptr && access(dir, mode) == 0 && check_runtime_path(dir) == 0) { + if (dir != nullptr && check_runtime_path(dir) == 0) { result = str2wcstring(dir); } else { // Don't rely on $USER being set, as setup_user() has not yet been called.