RESTRICT AUTOMERGE: Explicitly ignore the result of std::async
The newer libc++ marks std::async with [[nodiscard]] in C++20 mode.
Bug: b/175635923
Test: treehugger
Change-Id: Ia222778697ab4241f25e002073b3514c7e106007
diff --git a/services/surfaceflinger/SurfaceFlinger.cpp b/services/surfaceflinger/SurfaceFlinger.cpp
index 8c46515..64348a5 100644
--- a/services/surfaceflinger/SurfaceFlinger.cpp
+++ b/services/surfaceflinger/SurfaceFlinger.cpp
@@ -6755,7 +6755,7 @@
if (captureListener) {
// TODO: The future returned by std::async blocks the main thread. Return a chain of
// futures to the Binder thread instead.
- std::async([=]() mutable {
+ (void)std::async([=]() mutable {
ATRACE_NAME("captureListener is nonnull!");
auto fenceResult = renderFuture.get();
// TODO(b/232535621): Change ScreenCaptureResults to store a FenceResult.