Bug 1275766 - Invoke the proper URLValue constructor from Servo. r=heycam
authorBobby Holley <bobbyholley@gmail.com>
Tue, 24 May 2016 22:04:50 -0700
changeset 340149 9e8227f66e971a186de5638d0800bc302f6a1bd1
parent 340148 e9de9eee6be361530f7d5b1d1e2bc0be1d608cfe
child 340150 faf4134b30b9930c9650232f803f354fec6ec3e7
push id1183
push userraliiev@mozilla.com
push dateMon, 05 Sep 2016 20:01:49 +0000
treeherdermozilla-release@3148731bed45 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersheycam
bugs1275766
milestone49.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1275766 - Invoke the proper URLValue constructor from Servo. r=heycam Right now these are just coercing the values and invoking the main thread constructor.
layout/style/ServoBindings.cpp
--- a/layout/style/ServoBindings.cpp
+++ b/layout/style/ServoBindings.cpp
@@ -261,20 +261,18 @@ Gecko_SetMozBinding(nsStyleDisplay* aDis
 
   nsString url;
   nsDependentCSubstring urlString(reinterpret_cast<const char*>(aURLString),
                                   aURLStringLength);
   AppendUTF8toUTF16(urlString, url);
   RefPtr<nsStringBuffer> urlBuffer = nsCSSValue::BufferFromString(url);
 
   aDisplay->mBinding =
-    new css::URLValue(urlBuffer,
-                      nsMainThreadPtrHandle<nsIURI>(aBaseURI),
-                      nsMainThreadPtrHandle<nsIURI>(aReferrer),
-                      nsMainThreadPtrHandle<nsIPrincipal>(aPrincipal));
+    new css::URLValue(urlBuffer, do_AddRef(aBaseURI),
+                      do_AddRef(aReferrer), do_AddRef(aPrincipal));
 }
 
 void
 Gecko_CopyMozBindingFrom(nsStyleDisplay* aDest, const nsStyleDisplay* aSrc)
 {
   aDest->mBinding = aSrc->mBinding;
 }