Reland "libutils: disable implicit ref base construction"
This reverts commit 8e11f9e3f39617826201055c0af0ab740e9c7984.
Reason for revert: reland after fixing b/186028624
Bug: 184190315
Change-Id: Ia7339a46c3af7dd1a95bc82327cae5304f9f2e16
diff --git a/libutils/Threads.cpp b/libutils/Threads.cpp
index 540dcf4..1c8f810 100644
--- a/libutils/Threads.cpp
+++ b/libutils/Threads.cpp
@@ -693,7 +693,7 @@
mThread = thread_id_t(-1);
// hold a strong reference on ourself
- mHoldSelf = this;
+ mHoldSelf = sp<Thread>::fromExisting(this);
mRunning = true;