2023-01-11 00:40:45 +00:00
|
|
|
for some reason this breaks and the fd returned after close() after a few
|
2023-05-05 05:10:04 +00:00
|
|
|
cycles is still in the lock array.
|
2023-01-11 00:40:45 +00:00
|
|
|
|
|
|
|
so, just don't enforce or wrap anything.
|
2023-05-05 05:10:04 +00:00
|
|
|
|
|
|
|
note when testing this again: __close does not exist as a symbol in musl, so a
|
|
|
|
manual dlsym workaround has to be performed to use this codepath.
|
2023-01-11 00:40:45 +00:00
|
|
|
--- a/base/files/scoped_file_linux.cc
|
|
|
|
+++ b/base/files/scoped_file_linux.cc
|
|
|
|
@@ -77,15 +77,3 @@
|
|
|
|
}
|
|
|
|
|
|
|
|
} // namespace base
|
|
|
|
-
|
|
|
|
-extern "C" {
|
|
|
|
-
|
|
|
|
-int __close(int);
|
|
|
|
-
|
|
|
|
-__attribute__((visibility("default"), noinline)) int close(int fd) {
|
|
|
|
- if (base::IsFDOwned(fd) && g_is_ownership_enforced)
|
|
|
|
- CrashOnFdOwnershipViolation();
|
|
|
|
- return __close(fd);
|
|
|
|
-}
|
|
|
|
-
|
|
|
|
-} // extern "C"
|