mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1132528 - Handle non existent key r=nical
This commit is contained in:
parent
d768d0fcaf
commit
02956da7c1
@ -53,6 +53,10 @@ public:
|
||||
for (it = SharedBufferManagerParent::sManagers.begin(); it != SharedBufferManagerParent::sManagers.end(); it++) {
|
||||
base::ProcessId pid = it->first;
|
||||
SharedBufferManagerParent *mgr = it->second;
|
||||
if (!mgr) {
|
||||
printf_stderr("GrallocReporter::CollectReports() mgr is nullptr");
|
||||
continue;
|
||||
}
|
||||
|
||||
nsAutoCString pidName;
|
||||
LinuxUtils::GetThreadName(pid, pidName);
|
||||
@ -332,7 +336,11 @@ MessageLoop* SharedBufferManagerParent::GetMessageLoop()
|
||||
SharedBufferManagerParent* SharedBufferManagerParent::GetInstance(ProcessId id)
|
||||
{
|
||||
NS_ASSERTION(sManagers.count(id) == 1, "No BufferManager for the process");
|
||||
return sManagers[id];
|
||||
if (sManagers.count(id) == 1) {
|
||||
return sManagers[id];
|
||||
} else {
|
||||
return nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef MOZ_HAVE_SURFACEDESCRIPTORGRALLOC
|
||||
|
Loading…
Reference in New Issue
Block a user