fdsan: expose the address of the table to the platform.
Let the debuggerd handler get the address of the fdsan table so that
crash_dump can parse it and print it out in tombstones.
Test: debuggerd `pidof adbd`
Change-Id: I2297200cae52d0ff24479dba55d1ab4938583501
diff --git a/libc/bionic/fdsan.cpp b/libc/bionic/fdsan.cpp
index 918fd37..43d8831 100644
--- a/libc/bionic/fdsan.cpp
+++ b/libc/bionic/fdsan.cpp
@@ -139,6 +139,11 @@
return &__libc_shared_globals->fd_table;
}
+// Exposed to the platform to allow crash_dump to print out the fd table.
+extern "C" void* android_fdsan_get_fd_table() {
+ return GetFdTable();
+}
+
static FdEntry* GetFdEntry(int fd) {
if (fd < 0) {
return nullptr;