Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 46d4a1a8 authored by Steven Moreland's avatar Steven Moreland
Browse files

JavaBBinder::onTransact - log if env null

This can happen if ProcessState::self()->joinThreadPool() is called
from a thread that is started manually, for instance.

Fatal error is kept (would be SIGSEGV). We don't attach to the JVM
automatically here because it's a resource-intensive operation to
do automatically.

Bug: 225134223
Test: N/A
Change-Id: Ie75b3ee7591c7c07f79c567866f0d26570cf1a4c
parent 30e41a64
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -396,6 +396,9 @@ protected:
    {
        JNIEnv* env = javavm_to_jnienv(mVM);

        LOG_ALWAYS_FATAL_IF(env == nullptr,
                            "Binder thread started or Java binder used, but env null. Attach JVM?");

        ALOGV("onTransact() on %p calling object %p in env %p vm %p\n", this, mObject, env, mVM);

        IPCThreadState* thread_state = IPCThreadState::self();