Merge "Further harden the pad note parsing code." into main
diff --git a/OWNERS b/OWNERS
index 1859b9e..7455fd7 100644
--- a/OWNERS
+++ b/OWNERS
@@ -6,4 +6,4 @@
rprichard@google.com
yabinc@google.com
-per-file docs/mte.md=eugenis@google.com,fmayer@google.com,pcc@google.com
+per-file docs/mte.md=fmayer@google.com,pcc@google.com
diff --git a/libc/Android.bp b/libc/Android.bp
index d914983..794ccc7 100644
--- a/libc/Android.bp
+++ b/libc/Android.bp
@@ -104,8 +104,6 @@
},
apex_available: ["com.android.runtime"],
-
- tidy_disabled_srcs: ["upstream-*/**/*.c"],
}
// Workaround for b/24465209.
@@ -1629,9 +1627,7 @@
// which is default module for soong-defined system image.
visibility: [
"//bionic/apex",
- "//build/make/target/product/generic",
- //TODO(b/381985636) : Remove visibility to Soong-defined GSI once resolved
- "//build/make/target/product/gsi",
+ "//visibility:any_system_partition",
],
}
diff --git a/libc/include/sys/stat.h b/libc/include/sys/stat.h
index b6cdb14..12bfedc 100644
--- a/libc/include/sys/stat.h
+++ b/libc/include/sys/stat.h
@@ -216,10 +216,10 @@
*
* Returns 0 on success and returns -1 and sets `errno` on failure.
*/
-int fstatat(int __dir_fd, const char* _Nonnull __path, struct stat* _Nonnull __buf, int __flags);
+int fstatat(int __dir_fd, const char* _Nullable __path, struct stat* _Nonnull __buf, int __flags);
/** An alias for fstatat(). */
-int fstatat64(int __dir_fd, const char* _Nonnull __path, struct stat64* _Nonnull __buf, int __flags);
+int fstatat64(int __dir_fd, const char* _Nullable __path, struct stat64* _Nonnull __buf, int __flags);
/**
* [lstat(2)](https://man7.org/linux/man-pages/man2/lstat.2.html)
diff --git a/libc/malloc_debug/Android.bp b/libc/malloc_debug/Android.bp
index 5d61801..add6ba9 100644
--- a/libc/malloc_debug/Android.bp
+++ b/libc/malloc_debug/Android.bp
@@ -182,11 +182,6 @@
"bionic_libc_platform_headers",
],
- // The clang-analyzer-unix.Malloc and other warnings in these
- // unit tests are either false positive or in
- // negative tests that can be ignored.
- tidy: false,
-
srcs: [
"tests/malloc_debug_system_tests.cpp",
],
diff --git a/libc/malloc_hooks/Android.bp b/libc/malloc_hooks/Android.bp
index 3f0640b..06e91c6 100644
--- a/libc/malloc_hooks/Android.bp
+++ b/libc/malloc_hooks/Android.bp
@@ -60,11 +60,6 @@
name: "malloc_hooks_system_tests",
isolated: true,
- // The clang-analyzer-unix.Malloc and other warnings in these
- // unit tests are either false positive or in
- // negative tests that can be ignored.
- tidy: false,
-
srcs: [
"tests/malloc_hooks_tests.cpp",
],
diff --git a/libm/Android.bp b/libm/Android.bp
index ee86959..69cfb14 100644
--- a/libm/Android.bp
+++ b/libm/Android.bp
@@ -32,7 +32,6 @@
whole_static_libs: ["libarm-optimized-routines-math"],
- tidy_disabled_srcs: ["upstream-*/**/*.c"],
srcs: [
"upstream-freebsd/lib/msun/bsdsrc/b_tgamma.c",
"upstream-freebsd/lib/msun/src/catrig.c",
@@ -404,9 +403,6 @@
"-Wl,--Bsymbolic-functions",
],
- // b/120614316, non-critical readibility check
- tidy_checks: ["-cert-dcl16-c"],
-
include_dirs: ["bionic/libc"],
target: {
bionic: {
diff --git a/tests/Android.bp b/tests/Android.bp
index f227bbc..e2ac09a 100644
--- a/tests/Android.bp
+++ b/tests/Android.bp
@@ -379,9 +379,6 @@
"bionic_tests_defaults",
"large_system_property_node_defaults",
],
- tidy_disabled_srcs: [
- "malloc_test.cpp", // timed out with clang-tidy, and too many warnings
- ],
srcs: [
"__aeabi_read_tp_test.cpp",
"__cxa_atexit_test.cpp",
@@ -657,7 +654,6 @@
static_libs: [
"libbase",
],
- tidy: false,
target: {
musl: {
// Musl doesn't have fortify
@@ -666,12 +662,12 @@
},
}
-// Ensure we don't use FORTIFY'ed functions with the static analyzer/clang-tidy:
+// Ensure we don't use FORTIFY'ed functions with the clang static analyzer:
// it can confuse these tools pretty easily. If this builds successfully, then
// __clang_analyzer__ overrode FORTIFY. Otherwise, FORTIFY was incorrectly
// enabled. The library that results from building this is meant to be unused.
cc_test_library {
- name: "fortify_disabled_for_tidy",
+ name: "fortify_disabled_for_clang_analyzer",
defaults: [
"bionic_clang_fortify_tests_w_flags",
],
@@ -681,7 +677,6 @@
"-D__clang_analyzer__",
],
srcs: ["clang_fortify_tests.cpp"],
- tidy: false,
}
cc_test_library {
@@ -723,7 +718,6 @@
"-U_FORTIFY_SOURCE",
],
srcs: ["clang_fortify_tests.cpp"],
- tidy: false,
}
cc_test_library {
@@ -772,7 +766,6 @@
srcs: [
"clang_fortify_c_only_tests.c",
],
- tidy: false,
shared: {
enabled: false,
},
@@ -1428,7 +1421,6 @@
enabled: true,
},
},
- tidy: false,
clang_verify: true,
cflags: [
"-Wall",