commit | 4ff32df63d983ff0022524c360d1677c440155bd | [log] [tgz] |
---|---|---|
author | Primiano Tucci <primiano@google.com> | Thu Jul 27 16:33:34 2023 +0100 |
committer | Chinglin Yu <chinglinyu@google.com> | Fri Jul 28 14:41:22 2023 +0800 |
tree | b9ef12caddf823fd9690e770c816fa8a81744383 | |
parent | 207bb3eb405653a9bd53fe9914fd25d2384af989 [diff] |
socket: Introduce GetSockAddr() and improve test quality Adds a new method to UnixSocket and UnixSocketRaw which wraps getsockname() and returns a host:port string for the current socket. This is needed by aosp/2627899 and removes our fragile random port allocation code for tests, which can be replaced by a Bind() on port 0. Test: sudo modprobe vsock-loopback && perfetto_unittests --gtest_filter=UnixSocketTest.GetSockAddr* Bug: 284258446 Change-Id: Ia8b2d22e13f1ff872055983bc10eab6abe794bd9
Perfetto is a production-grade open-source stack for performance instrumentation and trace analysis. It offers services and libraries and for recording system-level and app-level traces, native + java heap profiling, a library for analyzing traces using SQL and a web-based UI to visualize and explore multi-GB traces.
See https://perfetto.dev/docs or the /docs/ directory for documentation.