Revert "RTM must to acquire lock before called IsMergedUnsafe (#28514)" (flutter/engine#28533)

This commit is contained in:
Kaushik Iska 2021-09-09 11:08:51 -07:00 committed by GitHub
parent a1df322e3d
commit 31087853c9
2 changed files with 2 additions and 4 deletions

View File

@ -91,9 +91,7 @@ bool RasterThreadMerger::IsOnPlatformThread() const {
return MessageLoop::GetCurrentTaskQueueId() == platform_queue_id_;
}
bool RasterThreadMerger::IsOnRasterizingThread() {
std::scoped_lock lock(mutex_);
bool RasterThreadMerger::IsOnRasterizingThread() const {
if (IsMergedUnSafe()) {
return IsOnPlatformThread();
} else {

View File

@ -89,7 +89,7 @@ class RasterThreadMerger
// Returns true if the current thread owns rasterizing.
// When the threads are merged, platform thread owns rasterizing.
// When un-merged, raster thread owns rasterizing.
bool IsOnRasterizingThread();
bool IsOnRasterizingThread() const;
// Returns true if the current thread is the platform thread.
bool IsOnPlatformThread() const;