Merge "frameworks/base: Make Thread::run threadName argument required" into nyc-dev

This commit is contained in:
Brian Carlstrom
2016-03-14 15:18:03 +00:00
committed by Android (Google) Code Review
2 changed files with 2 additions and 3 deletions

View File

@@ -1184,8 +1184,7 @@ static int javaDetachThread(void)
void** args = (void**) malloc(3 * sizeof(void*)); // javaThreadShell must free
int result;
if (!threadName)
threadName = "unnamed thread";
LOG_ALWAYS_FATAL_IF(threadName == nullptr, "threadName not provided to javaCreateThreadEtc");
args[0] = (void*) entryFunction;
args[1] = userData;

View File

@@ -400,7 +400,7 @@ int JTvInputHal::addOrUpdateStream(int deviceId, int streamId, const sp<Surface>
connection.mThread->shutdown();
}
connection.mThread = new BufferProducerThread(mDevice, deviceId, &stream);
connection.mThread->run();
connection.mThread->run("BufferProducerThread");
}
}
connection.mSurface = surface;