Error fix from enabling Clang thread-safety checks in Cuttlefish

Parent bug: b/353324127. Enabling `thread-safety-reference-return`
to allow developers to utilize Clang thread safety guardrails
(GUARDED_BY, REQUIRES, EXCLUDES).

Added NO_THREAD_SAFETY_ANALYSIS annotations to violating functions.
If this is not desired, please respond with concerns
or preferred fix.

Bug: 354740314
Flag: TEST_ONLY
Test: m out/soong/.intermediates/frameworks/native/services/surfaceflinger/tests/unittests/libsurfaceflinger_unittest/android_x86_silvermont/obj/frameworks/native/services/surfaceflinger/tests/unittests/CommitTest.o
Change-Id: I9be1254c3e2685b0aa950b314c581824f40ce26c
1 file changed