OSDN Git Service

Improve a comment.
authorElliott Hughes <enh@google.com>
Thu, 7 Jul 2011 17:45:03 +0000 (10:45 -0700)
committerElliott Hughes <enh@google.com>
Thu, 7 Jul 2011 17:45:03 +0000 (10:45 -0700)
Change-Id: If6636879dcdc15a33a083a19284de5fe8056e797

vm/Jni.cpp

index 218cdb8..ae23330 100644 (file)
@@ -349,7 +349,8 @@ Object* dvmDecodeIndirectRef(JNIEnv* env, jobject jobj) {
             IndirectRefTable* pRefTable = &gDvm.jniWeakGlobalRefTable;
             ScopedPthreadMutexLock lock(&gDvm.jniWeakGlobalRefLock);
             Object* result = pRefTable->get(jobj);
-            // A cleared weak global reference means we might legitimately return NULL here.
+            // There's no null check here because we might be dealing with
+            // a cleared weak global reference.
             /*
              * TODO: this is a temporary workaround for broken weak global
              * refs (http://b/4260055).  We treat any invalid reference as if it