media_addon_server: Fix use-after-free on quit.
Putting the add-ons uses the dormant node manager of the BMediaRoster. The BMediaRoster must therefore only be quit after all add-ons are put.
This commit is contained in:
parent
d0a9f6803b
commit
2c9e11ba38
@ -335,12 +335,12 @@ MediaAddonServer::QuitRequested()
|
||||
fSystemTimeSource = NULL;
|
||||
}
|
||||
|
||||
BMediaRoster::CurrentRoster()->Lock();
|
||||
BMediaRoster::CurrentRoster()->Quit();
|
||||
|
||||
for (iterator = fInfoMap.begin(); iterator != fInfoMap.end(); iterator++)
|
||||
_PutAddonIfPossible(iterator->second);
|
||||
|
||||
BMediaRoster::CurrentRoster()->Lock();
|
||||
BMediaRoster::CurrentRoster()->Quit();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user