Bug 1350140: Avoid dumb copy-constructor. r?heycam draft
authorEmilio Cobos Álvarez <emilio@crisal.io>
Sun, 26 Mar 2017 19:06:12 +0200
changeset 553202 2ecc51a80d491aa559766cf906a5c64e3f7cb426
parent 553201 ae759ce9604e426f7078e3f3088bbb26ad3b67d0
child 553203 208b4f2cc66daf7bf6be7f7766643b4be99cb282
push id51547
push userbmo:emilio+bugs@crisal.io
push dateWed, 29 Mar 2017 14:49:00 +0000
reviewersheycam
bugs1350140
milestone55.0a1
Bug 1350140: Avoid dumb copy-constructor. r?heycam MozReview-Commit-ID: CoCbXXYTfH4
layout/style/ServoBindings.cpp
--- a/layout/style/ServoBindings.cpp
+++ b/layout/style/ServoBindings.cpp
@@ -938,18 +938,17 @@ Gecko_CopyImageValueFrom(nsStyleImage* a
 
   *aImage = *aOther;
 }
 
 void
 Gecko_InitializeImageCropRect(nsStyleImage* aImage)
 {
   MOZ_ASSERT(aImage);
-  nsStyleSides cropRect;
-  aImage->SetCropRect(MakeUnique<nsStyleSides>(cropRect));
+  aImage->SetCropRect(MakeUnique<nsStyleSides>());
 }
 
 void
 Gecko_SetCursorArrayLength(nsStyleUserInterface* aStyleUI, size_t aLen)
 {
   aStyleUI->mCursorImages.Clear();
   aStyleUI->mCursorImages.SetLength(aLen);
 }