зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1693541 - Improve uses of nsBaseHashtable and descendants and avoid multiple subsequent lookups in toolkit/components/perfmonitoring. r=florian
Differential Revision: https://phabricator.services.mozilla.com/D106114
This commit is contained in:
Родитель
ee037ba882
Коммит
a47a075987
|
@ -242,14 +242,15 @@ PerformanceMetricsCollector::RequestMetricsInternal() {
|
|||
LOG(("[%s] Expecting %d results back", nsIDToCString(uuid).get(),
|
||||
numResultsRequired));
|
||||
results->SetNumResultsRequired(numResultsRequired);
|
||||
mAggregatedResults.InsertOrUpdate(uuid, std::move(results));
|
||||
const auto& aggregatedResult =
|
||||
mAggregatedResults.InsertOrUpdate(uuid, std::move(results));
|
||||
|
||||
// calling all content processes via IPDL (async)
|
||||
for (uint32_t i = 0; i < numChildren; i++) {
|
||||
if (NS_WARN_IF(!children[i]->SendRequestPerformanceMetrics(uuid))) {
|
||||
LOG(("[%s] Failed to send request to child %d", nsIDToCString(uuid).get(),
|
||||
i));
|
||||
mAggregatedResults.GetValue(uuid)->get()->Abort(NS_ERROR_FAILURE);
|
||||
aggregatedResult->Abort(NS_ERROR_FAILURE);
|
||||
return RequestMetricsPromise::CreateAndReject(NS_ERROR_FAILURE, __func__);
|
||||
}
|
||||
LOG(("[%s] Request sent to child %d", nsIDToCString(uuid).get(), i));
|
||||
|
|
Загрузка…
Ссылка в новой задаче