summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Steven Moreland <smoreland@google.com> 2022-10-04 19:54:51 +0000
committer Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> 2022-10-04 19:54:51 +0000
commit06c5b6efcddc03d1e20ad7c30740006c92ce8b51 (patch)
treec3d1369b62103560a48858364dde877874ee814c
parent2382dd3877b99064755d24664c895c658617a031 (diff)
parentcf31f8e773199522b8b053cde3d78fd6a0dab0a3 (diff)
Merge "binderRpcTest: actually include strong count in leaked ref" am: 9df841c82c am: c2bb53032f am: cf31f8e773
Original change: https://android-review.googlesource.com/c/platform/frameworks/native/+/2237852 Change-Id: I90b0dfe3b76f31ec32c0f5cccd8df3784452f93f Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
-rw-r--r--libs/binder/tests/binderRpcTest.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/libs/binder/tests/binderRpcTest.cpp b/libs/binder/tests/binderRpcTest.cpp
index 7a550f7e1a..652da991a4 100644
--- a/libs/binder/tests/binderRpcTest.cpp
+++ b/libs/binder/tests/binderRpcTest.cpp
@@ -181,9 +181,10 @@ struct ProcessSession {
wp<RpcSession> weakSession = session;
session = nullptr;
- EXPECT_EQ(nullptr, weakSession.promote())
+ sp<RpcSession> strongSession = weakSession.promote();
+ EXPECT_EQ(nullptr, strongSession)
<< (debugBacktrace(host.getPid()), debugBacktrace(getpid()), "Leaked sess: ")
- << session->getStrongCount();
+ << strongSession->getStrongCount();
}
}
};