summaryrefslogtreecommitdiffhomepage
path: root/test/util/fs_util.cc
diff options
context:
space:
mode:
Diffstat (limited to 'test/util/fs_util.cc')
-rw-r--r--test/util/fs_util.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/test/util/fs_util.cc b/test/util/fs_util.cc
index dffa16183..572675622 100644
--- a/test/util/fs_util.cc
+++ b/test/util/fs_util.cc
@@ -15,9 +15,9 @@
#include "test/util/fs_util.h"
#include <dirent.h>
-#ifndef __fuchsia__
+#ifdef __linux__
#include <linux/magic.h>
-#endif // __fuchsia__
+#endif // __linux__
#include <sys/stat.h>
#include <sys/statfs.h>
#include <sys/types.h>
@@ -633,7 +633,7 @@ PosixErrorOr<std::string> ProcessExePath(int pid) {
return ReadLink(absl::StrCat("/proc/", pid, "/exe"));
}
-#ifndef __fuchsia__
+#ifdef __linux__
PosixErrorOr<bool> IsTmpfs(const std::string& path) {
struct statfs stat;
if (statfs(path.c_str(), &stat)) {
@@ -647,7 +647,7 @@ PosixErrorOr<bool> IsTmpfs(const std::string& path) {
}
return stat.f_type == TMPFS_MAGIC;
}
-#endif // __fuchsia__
+#endif // __linux__
} // namespace testing
} // namespace gvisor