adbd: turn on fdsan warnings.

Test: mma
Test: python test_device.py
Change-Id: Ic90fac0b731b0aa9fa934f4472b0c40f1263c340
This commit is contained in:
Josh Gao 2018-07-25 18:13:44 -07:00
parent 6523309151
commit 954adcc541

View file

@ -18,6 +18,7 @@
#include "sysdeps.h"
#include <android/fdsan.h>
#include <errno.h>
#include <getopt.h>
#include <malloc.h>
@ -177,6 +178,11 @@ int adbd_main(int server_port) {
signal(SIGPIPE, SIG_IGN);
auto fdsan_level = android_fdsan_get_error_level();
if (fdsan_level == ANDROID_FDSAN_ERROR_LEVEL_DISABLED) {
android_fdsan_set_error_level(ANDROID_FDSAN_ERROR_LEVEL_WARN_ONCE);
}
init_transport_registration();
// We need to call this even if auth isn't enabled because the file