Merge "Fix a memory leak" am: a7dbdc8553 am: d8ce8e33e9 am: 584d6870c1

am: 6bb53c045a

Change-Id: I63f065aac01e743eb3a700d7b35b94312694b1e7
gugelfrei
George Burgess IV 6 years ago committed by android-build-merger
commit e32f08e97d

@ -546,8 +546,8 @@ void MediaProfiles::checkAndAddRequiredProfilesIfNecessary() {
if (info->mHasRefProfile) {
CamcorderProfile *profile =
new CamcorderProfile(
std::unique_ptr<CamcorderProfile> profile =
std::make_unique<CamcorderProfile>(
*mCamcorderProfiles[info->mRefProfileIndex]);
// Overwrite the quality
@ -581,7 +581,7 @@ void MediaProfiles::checkAndAddRequiredProfilesIfNecessary() {
mCamcorderProfiles[info->mRefProfileIndex]->mQuality,
profile->mQuality, cameraId);
mCamcorderProfiles.add(profile);
mCamcorderProfiles.add(profile.release());
}
}
}

Loading…
Cancel
Save