summaryrefslogtreecommitdiff
path: root/lib/sanitizer_common/sanitizer_platform_limits_posix.cc
diff options
context:
space:
mode:
authorAlexander Potapenko <glider@google.com>2013-10-31 17:38:18 +0000
committerAlexander Potapenko <glider@google.com>2013-10-31 17:38:18 +0000
commitb8a141f3783d796eabf45fabff82f3e08244e338 (patch)
treec65381f17ee6e581a93757842cf46fb135bd622f /lib/sanitizer_common/sanitizer_platform_limits_posix.cc
parentae7db43b4e8341c0f1c3166ffcf2b7c2aa7391f7 (diff)
[libsanitizer] Define SANITIZER_IOS when building for iOS or iOS simulator.
Do not use struct stat64 and struct statfs64 when building for iOS, where __DARWIN_ONLY_64_BIT_INO_T is set to 1. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@193775 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/sanitizer_common/sanitizer_platform_limits_posix.cc')
-rw-r--r--lib/sanitizer_common/sanitizer_platform_limits_posix.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/sanitizer_common/sanitizer_platform_limits_posix.cc b/lib/sanitizer_common/sanitizer_platform_limits_posix.cc
index 133ddcf23..22384771a 100644
--- a/lib/sanitizer_common/sanitizer_platform_limits_posix.cc
+++ b/lib/sanitizer_common/sanitizer_platform_limits_posix.cc
@@ -122,7 +122,9 @@
namespace __sanitizer {
unsigned struct_utsname_sz = sizeof(struct utsname);
unsigned struct_stat_sz = sizeof(struct stat);
+#if !SANITIZER_IOS
unsigned struct_stat64_sz = sizeof(struct stat64);
+#endif // !SANITIZER_IOS
unsigned struct_rusage_sz = sizeof(struct rusage);
unsigned struct_tm_sz = sizeof(struct tm);
unsigned struct_passwd_sz = sizeof(struct passwd);
@@ -143,9 +145,9 @@ namespace __sanitizer {
unsigned struct_sched_param_sz = sizeof(struct sched_param);
unsigned struct_statfs_sz = sizeof(struct statfs);
-#if SANITIZER_MAC
+#if SANITIZER_MAC && !SANITIZER_IOS
unsigned struct_statfs64_sz = sizeof(struct statfs64);
-#endif
+#endif // SANITIZER_MAC && !SANITIZER_IOS
#if !SANITIZER_ANDROID
unsigned ucontext_t_sz = sizeof(ucontext_t);