aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjbeich <jbeich@FreeBSD.org>2017-11-15 03:04:44 +0800
committerjbeich <jbeich@FreeBSD.org>2017-11-15 03:04:44 +0800
commitc7e3806384296b9ca776db951e4a76c91f6aae1b (patch)
treed0bbc8aaad1216e11badc746f6c83eaf42ec88cf
parentdc35789b1bca580e756af2002de30c86a36abd21 (diff)
downloadfreebsd-ports-gnome-c7e3806384296b9ca776db951e4a76c91f6aae1b.tar.gz
freebsd-ports-gnome-c7e3806384296b9ca776db951e4a76c91f6aae1b.tar.zst
freebsd-ports-gnome-c7e3806384296b9ca776db951e4a76c91f6aae1b.zip
www/firefox: update to 57.0 (marketed as "Firefox Quantum")
Not a MFH candidate due to POLA violation per redesigned UI, broken legacy addons and auto-reviewed new addons. Changes: https://www.mozilla.org/firefox/57.0/releasenotes/ PR: 222693 Tested by: pi, tobik, TrueOS
-rw-r--r--Mk/Uses/gecko.mk4
-rw-r--r--www/firefox-i18n/Makefile6
-rw-r--r--www/firefox-i18n/distinfo382
-rw-r--r--www/firefox/Makefile13
-rw-r--r--www/firefox/distinfo6
-rw-r--r--www/firefox/files/patch-a-bug1399540148
-rw-r--r--www/firefox/files/patch-bug126117525
-rw-r--r--www/firefox/files/patch-bug1325923121
-rw-r--r--www/firefox/files/patch-bug1343147117
-rw-r--r--www/firefox/files/patch-bug1355576262
-rw-r--r--www/firefox/files/patch-bug136589460
-rw-r--r--www/firefox/files/patch-bug1366420128
-rw-r--r--www/firefox/files/patch-bug136956166
-rw-r--r--www/firefox/files/patch-bug1370497100
-rw-r--r--www/firefox/files/patch-bug137514637
-rw-r--r--www/firefox/files/patch-bug1377587929
-rw-r--r--www/firefox/files/patch-bug1381761362
-rw-r--r--www/firefox/files/patch-bug1383019200
-rw-r--r--www/firefox/files/patch-bug1384121218
-rw-r--r--www/firefox/files/patch-bug1384701796
-rw-r--r--www/firefox/files/patch-bug138688789
-rw-r--r--www/firefox/files/patch-bug138695714
-rw-r--r--www/firefox/files/patch-bug138779949
-rw-r--r--www/firefox/files/patch-bug138781142
-rw-r--r--www/firefox/files/patch-bug138784538
-rw-r--r--www/firefox/files/patch-bug1393283144
-rw-r--r--www/firefox/files/patch-bug1394031387
-rw-r--r--www/firefox/files/patch-bug139426524
-rw-r--r--www/firefox/files/patch-bug139453060
-rw-r--r--www/firefox/files/patch-bug139513849
-rw-r--r--www/firefox/files/patch-bug139781148
-rw-r--r--www/firefox/files/patch-bug1399922104
-rw-r--r--www/firefox/files/patch-bug1400003120
-rw-r--r--www/firefox/files/patch-bug140055427
-rw-r--r--www/firefox/files/patch-bug140133976
-rw-r--r--www/firefox/files/patch-bug140157327
-rw-r--r--www/firefox/files/patch-bug140180431
-rw-r--r--www/firefox/files/patch-bug1402363199
-rw-r--r--www/firefox/files/patch-bug1402442181
-rw-r--r--www/firefox/files/patch-bug140287666
-rw-r--r--www/firefox/files/patch-bug140289640
-rw-r--r--www/firefox/files/patch-bug140296651
-rw-r--r--www/firefox/files/patch-bug1403646392
-rw-r--r--www/firefox/files/patch-bug1404324299
-rw-r--r--www/firefox/files/patch-bug1404636111
-rw-r--r--www/firefox/files/patch-bug1404910170
-rw-r--r--www/firefox/files/patch-bug140615453
-rw-r--r--www/firefox/files/patch-bug140639836
-rw-r--r--www/firefox/files/patch-bug140675047
-rw-r--r--www/firefox/files/patch-bug140703248
-rw-r--r--www/firefox/files/patch-bug140737528
-rw-r--r--www/firefox/files/patch-bug140774026
-rw-r--r--www/firefox/files/patch-bug140775135
-rw-r--r--www/firefox/files/patch-bug140800525
-rw-r--r--www/firefox/files/patch-bug140841237
-rw-r--r--www/firefox/files/patch-bug140878255
-rw-r--r--www/firefox/files/patch-bug140899034
-rw-r--r--www/firefox/files/patch-bug140968027
-rw-r--r--www/firefox/files/patch-bug141145844
-rw-r--r--www/firefox/files/patch-bug141225242
-rw-r--r--www/firefox/files/patch-bug8475682
-rw-r--r--www/firefox/files/patch-build-pgo-profileserver.py20
-rw-r--r--www/firefox/files/patch-servo1793453
-rw-r--r--www/firefox/files/patch-servo17969110
-rw-r--r--www/firefox/files/patch-servo18046763
-rw-r--r--www/firefox/files/patch-servo18126232
66 files changed, 216 insertions, 8319 deletions
diff --git a/Mk/Uses/gecko.mk b/Mk/Uses/gecko.mk
index 1be490172a79..432c60edd28e 100644
--- a/Mk/Uses/gecko.mk
+++ b/Mk/Uses/gecko.mk
@@ -37,12 +37,12 @@ RUN_DEPENDS+= libxul>=45:www/libxul
.elif ${gecko_ARGS:Mfirefox}
_GECKO_DEFAULT_VERSION= 52
-_GECKO_VERSIONS= 52 56
+_GECKO_VERSIONS= 52 57
_GECKO_TYPE= firefox
# Dependence lines for different Firefox versions
52_DEPENDS= ${LOCALBASE}/lib/firefox/firefox:www/firefox-esr
-56_DEPENDS= ${LOCALBASE}/lib/firefox/firefox:www/firefox
+57_DEPENDS= ${LOCALBASE}/lib/firefox/firefox:www/firefox
.if exists(${LOCALBASE}/bin/firefox)
_GECKO_INSTALLED_VER!= ${LOCALBASE}/bin/firefox --version 2>/dev/null
diff --git a/www/firefox-i18n/Makefile b/www/firefox-i18n/Makefile
index 2d34e53e1fbe..7e6498de06eb 100644
--- a/www/firefox-i18n/Makefile
+++ b/www/firefox-i18n/Makefile
@@ -2,10 +2,10 @@
# $FreeBSD$
PORTNAME= firefox-i18n
-PORTVERSION= 56.0.2
+PORTVERSION= 57.0
CATEGORIES= www
MASTER_SITES= MOZILLA/${PORTNAME:S|-i18n||}/releases/${DISTVERSION}/linux-i686/xpi \
- MOZILLA/${PORTNAME:S|-i18n||}/candidates/${DISTVERSION}-candidates/build1/linux-i686/xpi
+ MOZILLA/${PORTNAME:S|-i18n||}/candidates/${DISTVERSION}-candidates/build4/linux-i686/xpi
PKGNAMEPREFIX=
DISTFILES= ${FIREFOX_I18N_:S/$/.xpi/}
DIST_SUBDIR= xpi/${DISTNAME}
@@ -15,7 +15,7 @@ COMMENT= Localized interface for Firefox
EXTRACT_DEPENDS= zip:archivers/zip
-USES= zip:infozip gecko:firefox,56,build
+USES= zip:infozip gecko:firefox,57,build
USE_XPI= firefox
NO_ARCH= yes
diff --git a/www/firefox-i18n/distinfo b/www/firefox-i18n/distinfo
index 5361ed4719b4..0e05e1500cfa 100644
--- a/www/firefox-i18n/distinfo
+++ b/www/firefox-i18n/distinfo
@@ -1,191 +1,191 @@
-TIMESTAMP = 1508873487
-SHA256 (xpi/firefox-i18n-56.0.2/ach.xpi) = a78c4900c9dac71ea312d5ceda13987f4f8418ab078374c0e292cd30ce79aa23
-SIZE (xpi/firefox-i18n-56.0.2/ach.xpi) = 454896
-SHA256 (xpi/firefox-i18n-56.0.2/af.xpi) = e0ea5e99eb7cedd0c3893ae4baa3ca2af7f814bc069dcbf921069dcaba762fc6
-SIZE (xpi/firefox-i18n-56.0.2/af.xpi) = 456214
-SHA256 (xpi/firefox-i18n-56.0.2/an.xpi) = 18e3c4e6f85fb296bd955b110ba2c6a381ba4ba8de3a0e2990bc4618f9438593
-SIZE (xpi/firefox-i18n-56.0.2/an.xpi) = 475863
-SHA256 (xpi/firefox-i18n-56.0.2/ar.xpi) = c8dcb494321e5ef34092b7555ec67147461b387803df895c30858314f0509acb
-SIZE (xpi/firefox-i18n-56.0.2/ar.xpi) = 500711
-SHA256 (xpi/firefox-i18n-56.0.2/as.xpi) = e77f99a72083b49e30f453d1f40ac670e42e6a637b8bb4e7c914f74b24e6b582
-SIZE (xpi/firefox-i18n-56.0.2/as.xpi) = 508237
-SHA256 (xpi/firefox-i18n-56.0.2/ast.xpi) = e4fe6028af88b67dce678e6a1215cda2c2aa0cbe76eb95947c46e08d93bb23bc
-SIZE (xpi/firefox-i18n-56.0.2/ast.xpi) = 469157
-SHA256 (xpi/firefox-i18n-56.0.2/az.xpi) = 5d9cd26da6e1afe41c9d032054b066a9e0a13f7cfd9701e8126147f405ae6f1a
-SIZE (xpi/firefox-i18n-56.0.2/az.xpi) = 484984
-SHA256 (xpi/firefox-i18n-56.0.2/be.xpi) = 647318eb3b3060ba2384ecf4b4b96fb70fb54f1428c20f776d8d99f75eed5f49
-SIZE (xpi/firefox-i18n-56.0.2/be.xpi) = 531385
-SHA256 (xpi/firefox-i18n-56.0.2/bg.xpi) = a844374d3453747f30382acf6019d379596f812f68d49ba7245a18993cea5ffb
-SIZE (xpi/firefox-i18n-56.0.2/bg.xpi) = 528789
-SHA256 (xpi/firefox-i18n-56.0.2/bn-BD.xpi) = caafe8df84189999ed513e4f88e91f8b8c35e8a1d13fa54bd54f3a0654ec1f02
-SIZE (xpi/firefox-i18n-56.0.2/bn-BD.xpi) = 542772
-SHA256 (xpi/firefox-i18n-56.0.2/bn-IN.xpi) = 4278938cf3be47f2e7a865a2221c10f383b8c7930f71b2bd0c4ce09c1ff8a3c8
-SIZE (xpi/firefox-i18n-56.0.2/bn-IN.xpi) = 534450
-SHA256 (xpi/firefox-i18n-56.0.2/br.xpi) = 65e8b0a3e55e99701e0ecfb9cdb0775afc0946f23eab34d4ada4f0d973d2076d
-SIZE (xpi/firefox-i18n-56.0.2/br.xpi) = 464256
-SHA256 (xpi/firefox-i18n-56.0.2/bs.xpi) = fef54b5ba9231eaedbe216c1f9e7c86d831ed032d1fcd6e5dd15a06619ad69ac
-SIZE (xpi/firefox-i18n-56.0.2/bs.xpi) = 472256
-SHA256 (xpi/firefox-i18n-56.0.2/ca.xpi) = 11dc866f5f2a16622fa45c36c174150293e123bfd970890e4403ed224d6e4eb6
-SIZE (xpi/firefox-i18n-56.0.2/ca.xpi) = 480364
-SHA256 (xpi/firefox-i18n-56.0.2/cak.xpi) = 1ed05bcdb3977850ae21847f70122111ff459cc6669130ec9db5ccf11dde117f
-SIZE (xpi/firefox-i18n-56.0.2/cak.xpi) = 489507
-SHA256 (xpi/firefox-i18n-56.0.2/cs.xpi) = 1191121195a77ec1315ec379b307819f1ce6b15bfa1bb9fc31ec0148cb08bcf5
-SIZE (xpi/firefox-i18n-56.0.2/cs.xpi) = 485090
-SHA256 (xpi/firefox-i18n-56.0.2/cy.xpi) = a04d0d37f46b89d2aba85eebc1524daba41b3a6db468e61a924e83b2814d8845
-SIZE (xpi/firefox-i18n-56.0.2/cy.xpi) = 466288
-SHA256 (xpi/firefox-i18n-56.0.2/da.xpi) = 3822d31c6b83317216f5124d603d9a8b8180a06d2407426dd90b71891c155f0c
-SIZE (xpi/firefox-i18n-56.0.2/da.xpi) = 460091
-SHA256 (xpi/firefox-i18n-56.0.2/de.xpi) = ee02b96baf96be7e69ff12f06576a270e48ca454cc8f93c51070ebdd9c2a03f7
-SIZE (xpi/firefox-i18n-56.0.2/de.xpi) = 473856
-SHA256 (xpi/firefox-i18n-56.0.2/dsb.xpi) = 227588519f2ae092f6cbf0531287c5c36b7037c3355cc0d9e0e024d4e84472e3
-SIZE (xpi/firefox-i18n-56.0.2/dsb.xpi) = 489897
-SHA256 (xpi/firefox-i18n-56.0.2/el.xpi) = ace7c78e28297ea4dcc90a2b8c2881afc812a2416ae4cdba499749349bc2d3f3
-SIZE (xpi/firefox-i18n-56.0.2/el.xpi) = 554120
-SHA256 (xpi/firefox-i18n-56.0.2/en-GB.xpi) = 55fb37a478f2521b1b1543498d373ade08126c3ac71127bfbde504d8a3f95e16
-SIZE (xpi/firefox-i18n-56.0.2/en-GB.xpi) = 447375
-SHA256 (xpi/firefox-i18n-56.0.2/en-US.xpi) = 618f390c9a36aed65860d6ad20444c9c6224471d0a394de92a21262291327ff2
-SIZE (xpi/firefox-i18n-56.0.2/en-US.xpi) = 446951
-SHA256 (xpi/firefox-i18n-56.0.2/en-ZA.xpi) = 2fa254426d945152e9eb01cc02a8f86415fa5425aefed9825bd1dea9b6d0b76a
-SIZE (xpi/firefox-i18n-56.0.2/en-ZA.xpi) = 445916
-SHA256 (xpi/firefox-i18n-56.0.2/eo.xpi) = f1d9e7acc5bb36a2acfb1659ad0857e5d2c9800836d096f41ceb87977a6e7377
-SIZE (xpi/firefox-i18n-56.0.2/eo.xpi) = 468952
-SHA256 (xpi/firefox-i18n-56.0.2/es-AR.xpi) = 12f34c15fb4cf11e5c007ea19a97f91370a66e192cc3c0aed5405659be36eaa3
-SIZE (xpi/firefox-i18n-56.0.2/es-AR.xpi) = 475449
-SHA256 (xpi/firefox-i18n-56.0.2/es-CL.xpi) = 5239da279a01681c00ece001d1477abba04b41d50fd442e761140ba93b68870f
-SIZE (xpi/firefox-i18n-56.0.2/es-CL.xpi) = 479922
-SHA256 (xpi/firefox-i18n-56.0.2/es-ES.xpi) = 98b7422e833226916953ac89201652f406f84c805d293ab949adae475fc03a7c
-SIZE (xpi/firefox-i18n-56.0.2/es-ES.xpi) = 365631
-SHA256 (xpi/firefox-i18n-56.0.2/es-MX.xpi) = 9516c169b883f8208c996f461221e9bb917e2e56c1f67d01f67026a8f5de3a1b
-SIZE (xpi/firefox-i18n-56.0.2/es-MX.xpi) = 482565
-SHA256 (xpi/firefox-i18n-56.0.2/et.xpi) = dff5cbe5b933511fc10c1209dde31c45a521c9e687d909f4915eaf3eac8a3ad3
-SIZE (xpi/firefox-i18n-56.0.2/et.xpi) = 462104
-SHA256 (xpi/firefox-i18n-56.0.2/eu.xpi) = d47fe44fcab9328102334596678fe89289d8de44cd9018e13e1bcc70823ec6ec
-SIZE (xpi/firefox-i18n-56.0.2/eu.xpi) = 467884
-SHA256 (xpi/firefox-i18n-56.0.2/fa.xpi) = 8f25e71eb0ee9ad9e90d9948012713013ee03b6fe1b3837b1d903c5102be0a93
-SIZE (xpi/firefox-i18n-56.0.2/fa.xpi) = 522909
-SHA256 (xpi/firefox-i18n-56.0.2/ff.xpi) = b8416ca244cb8c99744dc3c6daa55d893754ed051ea9731f57b49edc2f0e18f1
-SIZE (xpi/firefox-i18n-56.0.2/ff.xpi) = 463098
-SHA256 (xpi/firefox-i18n-56.0.2/fi.xpi) = 1c6ecc0d72a500f5a77a8fdde5e288ce2c578bc1b1de3d1a062e6d7a71765130
-SIZE (xpi/firefox-i18n-56.0.2/fi.xpi) = 461923
-SHA256 (xpi/firefox-i18n-56.0.2/fr.xpi) = 3aa8e3e74e35a4e1ca948cb83b42bb9b2c95ec6abdbc8b0872129f6f75d4e2e1
-SIZE (xpi/firefox-i18n-56.0.2/fr.xpi) = 484561
-SHA256 (xpi/firefox-i18n-56.0.2/fy-NL.xpi) = 21b16ee4d0a232d6860c9fa6db296544e13e9500796451a98adebcdf35f88c66
-SIZE (xpi/firefox-i18n-56.0.2/fy-NL.xpi) = 478044
-SHA256 (xpi/firefox-i18n-56.0.2/ga-IE.xpi) = 4d780a2c0f362742f069842ae2d7ddf3dd8177e66405c9c570ef52b2e7de1f32
-SIZE (xpi/firefox-i18n-56.0.2/ga-IE.xpi) = 489379
-SHA256 (xpi/firefox-i18n-56.0.2/gd.xpi) = 9e4e1ffc31853fe3e0d4e9e23cd1ccdf0be1b50182cefc9581b902370a3ae2fc
-SIZE (xpi/firefox-i18n-56.0.2/gd.xpi) = 476927
-SHA256 (xpi/firefox-i18n-56.0.2/gl.xpi) = 7dc3615f3eca3bc09472207b8d78644923526dd51651a6a04cf8449bf78cca4b
-SIZE (xpi/firefox-i18n-56.0.2/gl.xpi) = 466468
-SHA256 (xpi/firefox-i18n-56.0.2/gn.xpi) = 32d64cb5ceb3a8b53abafd0699d9697f190e137155484fc06968efe3ab2da294
-SIZE (xpi/firefox-i18n-56.0.2/gn.xpi) = 485790
-SHA256 (xpi/firefox-i18n-56.0.2/gu-IN.xpi) = 574654d88abc8d620d5d29c09a281738ff463f8a0e09386373005a4c33cd7adf
-SIZE (xpi/firefox-i18n-56.0.2/gu-IN.xpi) = 513740
-SHA256 (xpi/firefox-i18n-56.0.2/he.xpi) = aa4437d071736c8009ff81f79cf51348fa7ce02d82dd603cc08c00997de79ddc
-SIZE (xpi/firefox-i18n-56.0.2/he.xpi) = 488495
-SHA256 (xpi/firefox-i18n-56.0.2/hi-IN.xpi) = 9faa3d8242f2e13e82334c91018137a23a88374d6d8bcbdbca0bac69b709487d
-SIZE (xpi/firefox-i18n-56.0.2/hi-IN.xpi) = 538303
-SHA256 (xpi/firefox-i18n-56.0.2/hr.xpi) = 78ea8859fc47c3fd35055ad7dacd3c89192619f637d1b10a5515db49c1aabd63
-SIZE (xpi/firefox-i18n-56.0.2/hr.xpi) = 475058
-SHA256 (xpi/firefox-i18n-56.0.2/hsb.xpi) = 7e868a01a8c881319703dd2d40aa7a90a2a6afda350a93cdee785c1cee3e334c
-SIZE (xpi/firefox-i18n-56.0.2/hsb.xpi) = 487599
-SHA256 (xpi/firefox-i18n-56.0.2/hu.xpi) = ba7c06ffe790cb31450c47ffc73c0ef402e759e8d6798c284ab3004aa9b1a154
-SIZE (xpi/firefox-i18n-56.0.2/hu.xpi) = 490102
-SHA256 (xpi/firefox-i18n-56.0.2/hy-AM.xpi) = 5a78e97fe3b0a106a9839714e2a811d52501e5c427ba9c943bdcbdd2beb303cb
-SIZE (xpi/firefox-i18n-56.0.2/hy-AM.xpi) = 527711
-SHA256 (xpi/firefox-i18n-56.0.2/id.xpi) = 916e89bb2bf8fcd0671a1cfe34944643e3f3bb1aeccf6bc7b86329e1f3261cb3
-SIZE (xpi/firefox-i18n-56.0.2/id.xpi) = 459066
-SHA256 (xpi/firefox-i18n-56.0.2/is.xpi) = f424cf833f52cb6a57933e6173bad7a1df2e01b9233feb0abfab0e9f3fd13a78
-SIZE (xpi/firefox-i18n-56.0.2/is.xpi) = 467447
-SHA256 (xpi/firefox-i18n-56.0.2/it.xpi) = 49e286eecc3e31a2581f728783f25717b994e466a1329f5121efff04d3400ccd
-SIZE (xpi/firefox-i18n-56.0.2/it.xpi) = 358695
-SHA256 (xpi/firefox-i18n-56.0.2/ja.xpi) = f981b5dd41b2d2479034720d4d8d4ec98b936e5d4b092e954057a3135b802d93
-SIZE (xpi/firefox-i18n-56.0.2/ja.xpi) = 527926
-SHA256 (xpi/firefox-i18n-56.0.2/ka.xpi) = c84ec7d427a84290cc760cf35a900a188621c7c8fbc3b48f63d7c000642eb3c1
-SIZE (xpi/firefox-i18n-56.0.2/ka.xpi) = 509096
-SHA256 (xpi/firefox-i18n-56.0.2/kab.xpi) = e8ffa26d1acef0cfb554eced0b86656c4ac504b5459bb8fd3eb86c5292df7b3e
-SIZE (xpi/firefox-i18n-56.0.2/kab.xpi) = 477420
-SHA256 (xpi/firefox-i18n-56.0.2/kk.xpi) = 5c918b32273f6a107c6a8d78be58c9e757884dcc28951949db39bba705c95d37
-SIZE (xpi/firefox-i18n-56.0.2/kk.xpi) = 534932
-SHA256 (xpi/firefox-i18n-56.0.2/km.xpi) = 52c280027d92449fda3cd321a091b2f65f401d417bff7fdce692191b748f99c2
-SIZE (xpi/firefox-i18n-56.0.2/km.xpi) = 549344
-SHA256 (xpi/firefox-i18n-56.0.2/kn.xpi) = 03120c4eb742e750c46f266fceb69cd1a8b97d3cf5bd0f2a55485d25af502272
-SIZE (xpi/firefox-i18n-56.0.2/kn.xpi) = 545517
-SHA256 (xpi/firefox-i18n-56.0.2/ko.xpi) = 60171b4d104a456df4a7fc60dc506eaa0ced1a32a216461bbddd2a215200f61b
-SIZE (xpi/firefox-i18n-56.0.2/ko.xpi) = 502895
-SHA256 (xpi/firefox-i18n-56.0.2/lij.xpi) = b0b07f9e4be734145b6472ef506b4cb99c85eea98ece31dad6efa2003d59f893
-SIZE (xpi/firefox-i18n-56.0.2/lij.xpi) = 467275
-SHA256 (xpi/firefox-i18n-56.0.2/lt.xpi) = 09302dfb196300ae49c47cf4a9a1ac9ec4df954defa8abd19bdd985852af94b5
-SIZE (xpi/firefox-i18n-56.0.2/lt.xpi) = 488753
-SHA256 (xpi/firefox-i18n-56.0.2/lv.xpi) = 9f47b7ef87c55320d6d67a15f61a87b0cc9e891a5aeac382badfe3e3b27b51e4
-SIZE (xpi/firefox-i18n-56.0.2/lv.xpi) = 481628
-SHA256 (xpi/firefox-i18n-56.0.2/mai.xpi) = f16a670648ebdc3b914620d7fbe4f6095952f65c658901ecfcfbbc37645f5fdb
-SIZE (xpi/firefox-i18n-56.0.2/mai.xpi) = 524702
-SHA256 (xpi/firefox-i18n-56.0.2/mk.xpi) = e537b92b6af439a1c1b9e667939f146b7a2ad17eae3d4f9075d1ad70bb958b0f
-SIZE (xpi/firefox-i18n-56.0.2/mk.xpi) = 507818
-SHA256 (xpi/firefox-i18n-56.0.2/ml.xpi) = 5714a5481f111e1467a596973c824e9d09cb1e464cc74c332582d5079b495efd
-SIZE (xpi/firefox-i18n-56.0.2/ml.xpi) = 547547
-SHA256 (xpi/firefox-i18n-56.0.2/mr.xpi) = 2993e10fa67e526691859805b5bf928be5607d59ceedbbb7aa68962688fa6723
-SIZE (xpi/firefox-i18n-56.0.2/mr.xpi) = 536673
-SHA256 (xpi/firefox-i18n-56.0.2/ms.xpi) = 7b4a6353a3b2e6e2fc923dc43191c0bc463aeacc9d9eaadb032f93f00376b6df
-SIZE (xpi/firefox-i18n-56.0.2/ms.xpi) = 466107
-SHA256 (xpi/firefox-i18n-56.0.2/my.xpi) = 9ef461ae9ec46bc6198456411232ed37a0ed68f11d4bc587d2b8b4d8247868d5
-SIZE (xpi/firefox-i18n-56.0.2/my.xpi) = 536722
-SHA256 (xpi/firefox-i18n-56.0.2/nb-NO.xpi) = ee407654fbfad2523ec72fc921b9072772bacc231636b460ac239c406a43132f
-SIZE (xpi/firefox-i18n-56.0.2/nb-NO.xpi) = 465575
-SHA256 (xpi/firefox-i18n-56.0.2/nl.xpi) = bbba1d13636b0f03868d202893eb995f3112a56ac2453bbdde6b8fb856fe49b1
-SIZE (xpi/firefox-i18n-56.0.2/nl.xpi) = 469053
-SHA256 (xpi/firefox-i18n-56.0.2/nn-NO.xpi) = 8120d52f0e9a0ecd870a0ea0d3b887df12b129d3bfda7c83f09e4036907d08e6
-SIZE (xpi/firefox-i18n-56.0.2/nn-NO.xpi) = 466208
-SHA256 (xpi/firefox-i18n-56.0.2/or.xpi) = 325acd5539ec48f65320ff0f5768fbdced82c788750f7c0cd00bf2a264751e32
-SIZE (xpi/firefox-i18n-56.0.2/or.xpi) = 518165
-SHA256 (xpi/firefox-i18n-56.0.2/pa-IN.xpi) = 2e3bcfc268606f1496226ca549df40e9c6b8b9f972cdd7f84d4d5c4b32173294
-SIZE (xpi/firefox-i18n-56.0.2/pa-IN.xpi) = 509046
-SHA256 (xpi/firefox-i18n-56.0.2/pl.xpi) = c6123361207e67bfd6f859c65c369fa0b22561fbb46b548d9b322433f209a712
-SIZE (xpi/firefox-i18n-56.0.2/pl.xpi) = 377524
-SHA256 (xpi/firefox-i18n-56.0.2/pt-BR.xpi) = 3a45de0fd1d0b18123e4f97de1de8f57c043a8c621a02f5267643fc5fb12c8bf
-SIZE (xpi/firefox-i18n-56.0.2/pt-BR.xpi) = 470954
-SHA256 (xpi/firefox-i18n-56.0.2/pt-PT.xpi) = b8412464435c2e3c79017bc7ecc6b7b7d7715b1b47d0ca5f6e7c320d2c2b87d1
-SIZE (xpi/firefox-i18n-56.0.2/pt-PT.xpi) = 472803
-SHA256 (xpi/firefox-i18n-56.0.2/rm.xpi) = 2054926b1f43459aa857234466b686553555e2afc2e6072ef3883f28b2ebc676
-SIZE (xpi/firefox-i18n-56.0.2/rm.xpi) = 467019
-SHA256 (xpi/firefox-i18n-56.0.2/ro.xpi) = d69ce50c34f429d4a6724b4b8d954bb3f78e5a7fb42302c2e9de9e5f870c4e0e
-SIZE (xpi/firefox-i18n-56.0.2/ro.xpi) = 470785
-SHA256 (xpi/firefox-i18n-56.0.2/ru.xpi) = 2339cce445c2c01de77fd89079c121301dfcc082f9f8e3b0f640d0f42a648cac
-SIZE (xpi/firefox-i18n-56.0.2/ru.xpi) = 541437
-SHA256 (xpi/firefox-i18n-56.0.2/si.xpi) = 79c3fa18f421923b48505b74e39cd4fab474685584bb5daf71f41ebd8a388402
-SIZE (xpi/firefox-i18n-56.0.2/si.xpi) = 515921
-SHA256 (xpi/firefox-i18n-56.0.2/sk.xpi) = 0292ae81d9ae0af15489b2b420f3156cb2f7266cd881deaa4c9e164c987271c7
-SIZE (xpi/firefox-i18n-56.0.2/sk.xpi) = 495563
-SHA256 (xpi/firefox-i18n-56.0.2/sl.xpi) = bea8af482218c1bfde800e3461f64d008b46b1419745127fe838a29724098b5f
-SIZE (xpi/firefox-i18n-56.0.2/sl.xpi) = 473806
-SHA256 (xpi/firefox-i18n-56.0.2/son.xpi) = 6f93b52c42355adafc0778516defce16af99a17ee41ec0d25003ab39bfc6dda1
-SIZE (xpi/firefox-i18n-56.0.2/son.xpi) = 464322
-SHA256 (xpi/firefox-i18n-56.0.2/sq.xpi) = 867d12980a8d3ee7ae28faa4f09f63ed405f9ea18b6c0c776da8194ecda937ed
-SIZE (xpi/firefox-i18n-56.0.2/sq.xpi) = 479511
-SHA256 (xpi/firefox-i18n-56.0.2/sr.xpi) = b300ada0279186be68dbf292d41d446828acc71e3dcca94cf88a2ef34b38abc9
-SIZE (xpi/firefox-i18n-56.0.2/sr.xpi) = 504487
-SHA256 (xpi/firefox-i18n-56.0.2/sv-SE.xpi) = 0ccdf643e1f62ff1e41ceb3fe9c35191aece0efcbfc6b24293f88f7ef1d55043
-SIZE (xpi/firefox-i18n-56.0.2/sv-SE.xpi) = 473949
-SHA256 (xpi/firefox-i18n-56.0.2/ta.xpi) = 0186d38239a9db92394562eb70a6960eeeee052abce62bc3672c8644a37cb859
-SIZE (xpi/firefox-i18n-56.0.2/ta.xpi) = 530646
-SHA256 (xpi/firefox-i18n-56.0.2/te.xpi) = 789359330bdfefb1fc379582b098c040cdb6a46f770e2c80b1695a7eb634db40
-SIZE (xpi/firefox-i18n-56.0.2/te.xpi) = 549585
-SHA256 (xpi/firefox-i18n-56.0.2/th.xpi) = abeb0f7ff018d44efbcea4cba5c0c62a78f42f6395ea1535f757f2045064c880
-SIZE (xpi/firefox-i18n-56.0.2/th.xpi) = 520297
-SHA256 (xpi/firefox-i18n-56.0.2/tr.xpi) = b3798722e3a732e422a1fbff8d1c9ca7716b3fe9b2f21cc219432ec998556e26
-SIZE (xpi/firefox-i18n-56.0.2/tr.xpi) = 480549
-SHA256 (xpi/firefox-i18n-56.0.2/uk.xpi) = 6854f076f5ef93e72a4f38f03a8dadc61e3a2f8afa402783bbd00bcc63b6f14f
-SIZE (xpi/firefox-i18n-56.0.2/uk.xpi) = 535436
-SHA256 (xpi/firefox-i18n-56.0.2/ur.xpi) = 01a4d64725be568e148d88dab405545f76a24a695d499a236a2be0599489324a
-SIZE (xpi/firefox-i18n-56.0.2/ur.xpi) = 527354
-SHA256 (xpi/firefox-i18n-56.0.2/uz.xpi) = 79092d2f830adbf05cc884aa014fa9348e3449fa206cf91286d5bfb40ebe729c
-SIZE (xpi/firefox-i18n-56.0.2/uz.xpi) = 475101
-SHA256 (xpi/firefox-i18n-56.0.2/vi.xpi) = 65633b00c1a124a23bfda2bdb7666ab8e12e113c956930cc975f838e3de04038
-SIZE (xpi/firefox-i18n-56.0.2/vi.xpi) = 487150
-SHA256 (xpi/firefox-i18n-56.0.2/xh.xpi) = af99554dc838c042310acbb0a7c2623d61ff3b3045667cf301cffeb29821c008
-SIZE (xpi/firefox-i18n-56.0.2/xh.xpi) = 477838
-SHA256 (xpi/firefox-i18n-56.0.2/zh-CN.xpi) = f2a1bb04222fbca3845b00694342a74c8d54cbf1a64104d96f1856879aed0abf
-SIZE (xpi/firefox-i18n-56.0.2/zh-CN.xpi) = 498979
-SHA256 (xpi/firefox-i18n-56.0.2/zh-TW.xpi) = 8c547d631522048d060be5305c277024e8038386dcad232ed742b1edf14a9471
-SIZE (xpi/firefox-i18n-56.0.2/zh-TW.xpi) = 497765
+TIMESTAMP = 1510498738
+SHA256 (xpi/firefox-i18n-57.0/ach.xpi) = ff5bbdfcca5270cf978173eb13ce10bfb4b51dbd1faeb9b69c50f689a1eb3dc4
+SIZE (xpi/firefox-i18n-57.0/ach.xpi) = 441112
+SHA256 (xpi/firefox-i18n-57.0/af.xpi) = 65459a5914dba1de876bee7d867699ff033a9722a957675f973b5cf1213366b9
+SIZE (xpi/firefox-i18n-57.0/af.xpi) = 442205
+SHA256 (xpi/firefox-i18n-57.0/an.xpi) = d24b77cfdf3d5badd492c04f5984171bedbafcee31fb447930925e2c911e5261
+SIZE (xpi/firefox-i18n-57.0/an.xpi) = 462777
+SHA256 (xpi/firefox-i18n-57.0/ar.xpi) = 06b0d8f7f34eb661f8f4944c26ddeee81e84bb00dd07dec4f1f06e54f1cdbe6f
+SIZE (xpi/firefox-i18n-57.0/ar.xpi) = 488159
+SHA256 (xpi/firefox-i18n-57.0/as.xpi) = 8229d02b5f8b88dea2a6e8f83db6c335c951ebf786f4d73fe28dde8457ae4d59
+SIZE (xpi/firefox-i18n-57.0/as.xpi) = 491074
+SHA256 (xpi/firefox-i18n-57.0/ast.xpi) = 0f46b1d36c23ec86656208241e692f2f4fef6338285dd54621939a53672d497d
+SIZE (xpi/firefox-i18n-57.0/ast.xpi) = 455503
+SHA256 (xpi/firefox-i18n-57.0/az.xpi) = 68db90d2cc24227407dc20cb8721b5f89ae875fc3e0248981bf5349b2348030d
+SIZE (xpi/firefox-i18n-57.0/az.xpi) = 466042
+SHA256 (xpi/firefox-i18n-57.0/be.xpi) = 9e9c151874180d2ccf6ac1e7e7a59a5d2e72f9543bb6c128416fad177a2f01cb
+SIZE (xpi/firefox-i18n-57.0/be.xpi) = 516091
+SHA256 (xpi/firefox-i18n-57.0/bg.xpi) = 10c386468c1d34676a7d4e3992f14d853cd29f61bd1d12b04f3f1b66ebb8993b
+SIZE (xpi/firefox-i18n-57.0/bg.xpi) = 510349
+SHA256 (xpi/firefox-i18n-57.0/bn-BD.xpi) = 11b541a18a34fee16337dd8648a36e45b6c5371e9c17a845985120e6a7b1997d
+SIZE (xpi/firefox-i18n-57.0/bn-BD.xpi) = 527188
+SHA256 (xpi/firefox-i18n-57.0/bn-IN.xpi) = f8c912705b760607456a140506f3120e9d7c9f0ee17508d4cbd1eb3e18bc895d
+SIZE (xpi/firefox-i18n-57.0/bn-IN.xpi) = 516175
+SHA256 (xpi/firefox-i18n-57.0/br.xpi) = 4c76bf9c4b39dac467de391527072ca6d81c83a9ccbead46dbbbb76a8ab7c252
+SIZE (xpi/firefox-i18n-57.0/br.xpi) = 451865
+SHA256 (xpi/firefox-i18n-57.0/bs.xpi) = 4d3c483b4e3a20a852ddb5fe6a0d1f447366310dee446317017ebdf332e129c1
+SIZE (xpi/firefox-i18n-57.0/bs.xpi) = 459649
+SHA256 (xpi/firefox-i18n-57.0/ca.xpi) = 21fc2934acb751e89badbf215aad67085c310cbb627e44277d9592aaf213a837
+SIZE (xpi/firefox-i18n-57.0/ca.xpi) = 466640
+SHA256 (xpi/firefox-i18n-57.0/cak.xpi) = 95c3cff1bd43dc2f14e99a0c10d8f101beb4e940f810279a2912571ddeff6326
+SIZE (xpi/firefox-i18n-57.0/cak.xpi) = 475934
+SHA256 (xpi/firefox-i18n-57.0/cs.xpi) = c579929028397c8f93ed7193cc4f2a6511a5b503d59d02d6599701d7fab393db
+SIZE (xpi/firefox-i18n-57.0/cs.xpi) = 469456
+SHA256 (xpi/firefox-i18n-57.0/cy.xpi) = 3442262d271a47173226ae327be47524ab0237b0ebaea73c61c61177463f81fa
+SIZE (xpi/firefox-i18n-57.0/cy.xpi) = 455787
+SHA256 (xpi/firefox-i18n-57.0/da.xpi) = 538e9cce1e72af3ce6c6bbfe0a310529099dc95100546974e8b0a228860854a3
+SIZE (xpi/firefox-i18n-57.0/da.xpi) = 448415
+SHA256 (xpi/firefox-i18n-57.0/de.xpi) = bb4c883efe6f393ed47d91712901ca0bff04951db9e83ab5c981811e60512461
+SIZE (xpi/firefox-i18n-57.0/de.xpi) = 460812
+SHA256 (xpi/firefox-i18n-57.0/dsb.xpi) = 51ef0a8a83770dab060779d6b34478a60d080e743b8c446b791a89236161f29e
+SIZE (xpi/firefox-i18n-57.0/dsb.xpi) = 479506
+SHA256 (xpi/firefox-i18n-57.0/el.xpi) = 2009672fb40a593061fba725ad6fb5c6b52b330a7724e3e5203c8885df5fce81
+SIZE (xpi/firefox-i18n-57.0/el.xpi) = 534482
+SHA256 (xpi/firefox-i18n-57.0/en-GB.xpi) = 404f4dd5d724ceacdd49b63f303ceeae4608f8e989992ebca71198251023fc7f
+SIZE (xpi/firefox-i18n-57.0/en-GB.xpi) = 435622
+SHA256 (xpi/firefox-i18n-57.0/en-US.xpi) = ac8b76c6ad2f10b62c784cb97b30b7c8cf0b466102a3732199a2ce5f355aa0db
+SIZE (xpi/firefox-i18n-57.0/en-US.xpi) = 441879
+SHA256 (xpi/firefox-i18n-57.0/en-ZA.xpi) = f1d21809cccea7d4bc649b7337ebde96f3b42185d154e603dbae241e5d8876d1
+SIZE (xpi/firefox-i18n-57.0/en-ZA.xpi) = 432019
+SHA256 (xpi/firefox-i18n-57.0/eo.xpi) = 599314153f217433a53671ac0c118be5a6953094bcd94fe8230f192ca5d8995a
+SIZE (xpi/firefox-i18n-57.0/eo.xpi) = 454908
+SHA256 (xpi/firefox-i18n-57.0/es-AR.xpi) = 6f6d9805f9bba0fac0afce20bdfb1116c1c441cb5463fc271e8a3cec2cfe2bfe
+SIZE (xpi/firefox-i18n-57.0/es-AR.xpi) = 462978
+SHA256 (xpi/firefox-i18n-57.0/es-CL.xpi) = 141b2502ed61b7ac439910c252c6de9388ab6a6783fb290e77208367317b4fdc
+SIZE (xpi/firefox-i18n-57.0/es-CL.xpi) = 465514
+SHA256 (xpi/firefox-i18n-57.0/es-ES.xpi) = 73409303fc344d642f2343fd683694b534291c6ca5a8f8c63ee27b13e2ffe8ab
+SIZE (xpi/firefox-i18n-57.0/es-ES.xpi) = 353623
+SHA256 (xpi/firefox-i18n-57.0/es-MX.xpi) = dd136cbdbe64a77341d8345c388f6ca63e5acbf65ba2f7ef7d61af52bdbcbf61
+SIZE (xpi/firefox-i18n-57.0/es-MX.xpi) = 468760
+SHA256 (xpi/firefox-i18n-57.0/et.xpi) = e5683bf2280fd070dad6855af2f60bd433d9200af66ec0976f5045d5d44e8e30
+SIZE (xpi/firefox-i18n-57.0/et.xpi) = 447277
+SHA256 (xpi/firefox-i18n-57.0/eu.xpi) = 562f0ad72e23e6b37969c6b75fd7343cbceb67cfb3db570525b796c3a214b2b2
+SIZE (xpi/firefox-i18n-57.0/eu.xpi) = 454671
+SHA256 (xpi/firefox-i18n-57.0/fa.xpi) = 39891a98174cdf50dfea0a69e896049ef8aa66be1c694149eb7da3ff421045a2
+SIZE (xpi/firefox-i18n-57.0/fa.xpi) = 510827
+SHA256 (xpi/firefox-i18n-57.0/ff.xpi) = 0b9a56e8b6378b13db3011957c9e040c3b2e74afe8de34d0333b9029b15d3f38
+SIZE (xpi/firefox-i18n-57.0/ff.xpi) = 454014
+SHA256 (xpi/firefox-i18n-57.0/fi.xpi) = b81be3f2dd15873dae20b4eced377e3e8d3b40de59d7735c72444e87dc7f476e
+SIZE (xpi/firefox-i18n-57.0/fi.xpi) = 446242
+SHA256 (xpi/firefox-i18n-57.0/fr.xpi) = 59578e90b9832f216d01755cd52bc5956fa646bc420131f3b00ce09faa8d6271
+SIZE (xpi/firefox-i18n-57.0/fr.xpi) = 472720
+SHA256 (xpi/firefox-i18n-57.0/fy-NL.xpi) = 529719f9de24ed1a1573d8a55f91d2cbafdaa37d06c65ced206815622668fe8f
+SIZE (xpi/firefox-i18n-57.0/fy-NL.xpi) = 465907
+SHA256 (xpi/firefox-i18n-57.0/ga-IE.xpi) = 563933a54d94fa031fb309157d806b50e694ae42e6723d9a5b6e442fd5d53f21
+SIZE (xpi/firefox-i18n-57.0/ga-IE.xpi) = 475962
+SHA256 (xpi/firefox-i18n-57.0/gd.xpi) = 69089bd588762270bd6592b544ed7886b4d092b915cdabb4ffee6c9c499ed924
+SIZE (xpi/firefox-i18n-57.0/gd.xpi) = 465121
+SHA256 (xpi/firefox-i18n-57.0/gl.xpi) = ca5195dad2f043d4b530b414061c92f835fe0f9c2f0e8a64de0e3a73079e4e6d
+SIZE (xpi/firefox-i18n-57.0/gl.xpi) = 452030
+SHA256 (xpi/firefox-i18n-57.0/gn.xpi) = a118e4b81c47da417fe79af3d95788e04aaf42d433e8984d026851c41cd5ee11
+SIZE (xpi/firefox-i18n-57.0/gn.xpi) = 471954
+SHA256 (xpi/firefox-i18n-57.0/gu-IN.xpi) = 0cf3579447aa63d495d5ee744d7b7dcd16eb6779c8e398f75a3c12841c1f2461
+SIZE (xpi/firefox-i18n-57.0/gu-IN.xpi) = 511989
+SHA256 (xpi/firefox-i18n-57.0/he.xpi) = a2c770fab1787623f9a62a5579e7e2f5e8561ba38f8223ef11c75227abd5c7f3
+SIZE (xpi/firefox-i18n-57.0/he.xpi) = 471920
+SHA256 (xpi/firefox-i18n-57.0/hi-IN.xpi) = a07ecdd23d74ea5ae916b4a94ad513696e4000f703ea3e06cdff9c579748e1c2
+SIZE (xpi/firefox-i18n-57.0/hi-IN.xpi) = 526109
+SHA256 (xpi/firefox-i18n-57.0/hr.xpi) = f88a0964a4e55a4b904e3e466d78f853b58f99007f920277651b4176f48c1cbd
+SIZE (xpi/firefox-i18n-57.0/hr.xpi) = 460720
+SHA256 (xpi/firefox-i18n-57.0/hsb.xpi) = bbdb24808af0f07be665ffc8cadf687ef30c47075d0b1ef78a58311ddbf99f7f
+SIZE (xpi/firefox-i18n-57.0/hsb.xpi) = 476500
+SHA256 (xpi/firefox-i18n-57.0/hu.xpi) = 23767b357e4ae9a470605a7bf5e5231301ffe3d65fea8e11c07f82f53e1fd9c2
+SIZE (xpi/firefox-i18n-57.0/hu.xpi) = 476603
+SHA256 (xpi/firefox-i18n-57.0/hy-AM.xpi) = 8106177a21fbfb382dfe26b6106ba35128a03fc25d06b492f948c7a661303add
+SIZE (xpi/firefox-i18n-57.0/hy-AM.xpi) = 510824
+SHA256 (xpi/firefox-i18n-57.0/id.xpi) = a3cce07b6c2369bfed1c47af5fd3de8254603efe8b7d3e3929ddba32d824237a
+SIZE (xpi/firefox-i18n-57.0/id.xpi) = 444040
+SHA256 (xpi/firefox-i18n-57.0/is.xpi) = b608ebb8f34a93968fcef85d1c463e32489e999b92197f9b21b094d76db29767
+SIZE (xpi/firefox-i18n-57.0/is.xpi) = 452655
+SHA256 (xpi/firefox-i18n-57.0/it.xpi) = b035b10133444b23fbef2c66c8548fdd6703ec304d8a854c5fbec42e79f9778a
+SIZE (xpi/firefox-i18n-57.0/it.xpi) = 347170
+SHA256 (xpi/firefox-i18n-57.0/ja.xpi) = a7e3af1bbc6bdf3ec139e77e3cc1e39b072dd68b0a434ef96cc288e7424eea8c
+SIZE (xpi/firefox-i18n-57.0/ja.xpi) = 508551
+SHA256 (xpi/firefox-i18n-57.0/ka.xpi) = 09dd38e2f51b0228dd0302e4afcc6ee6f6f2d89956172c27518cb9c7423e155e
+SIZE (xpi/firefox-i18n-57.0/ka.xpi) = 492355
+SHA256 (xpi/firefox-i18n-57.0/kab.xpi) = f673912bcc909e9046008803886cf4322653871e7b5b121645566c2b92b5fc39
+SIZE (xpi/firefox-i18n-57.0/kab.xpi) = 462530
+SHA256 (xpi/firefox-i18n-57.0/kk.xpi) = 4d93c3e6f982f4b10d614f6d237f8fac8887c347f1ce11aa6728d0918d552a87
+SIZE (xpi/firefox-i18n-57.0/kk.xpi) = 519248
+SHA256 (xpi/firefox-i18n-57.0/km.xpi) = 11cb79e402ba96e678fa27bdbd39bb7ec48533eac89f884334b65ad9335eef54
+SIZE (xpi/firefox-i18n-57.0/km.xpi) = 530079
+SHA256 (xpi/firefox-i18n-57.0/kn.xpi) = 1230fe7d27fbc3af7196b7258bee255b4d85dd232c117a0a4d515ddef74328c9
+SIZE (xpi/firefox-i18n-57.0/kn.xpi) = 531315
+SHA256 (xpi/firefox-i18n-57.0/ko.xpi) = 1d992cbc4f30bff88b40d46c55ceef223f7b66ad489e073a859655461edacb28
+SIZE (xpi/firefox-i18n-57.0/ko.xpi) = 487304
+SHA256 (xpi/firefox-i18n-57.0/lij.xpi) = 4e9e6e0661c4bea860128dd870596154e68c3367624fd6cbc690e2c341157f21
+SIZE (xpi/firefox-i18n-57.0/lij.xpi) = 452340
+SHA256 (xpi/firefox-i18n-57.0/lt.xpi) = ce3bdff82d4f6baef44d2913e4da76b83e50dd0c9e3102e444425d379e2347f7
+SIZE (xpi/firefox-i18n-57.0/lt.xpi) = 474955
+SHA256 (xpi/firefox-i18n-57.0/lv.xpi) = 25bb6e484402d0c7909544031c2fe84f04b8cb0d563c902427542ca8b0f0a996
+SIZE (xpi/firefox-i18n-57.0/lv.xpi) = 465242
+SHA256 (xpi/firefox-i18n-57.0/mai.xpi) = 7f3dafefb77ef7d5e73dd9a762b9d51f05c7c739933561b3a0d53c7798fff9d9
+SIZE (xpi/firefox-i18n-57.0/mai.xpi) = 507395
+SHA256 (xpi/firefox-i18n-57.0/mk.xpi) = ac348da0f832916715da5111083a4e2b72a7d16b9c96c04a1cc4d5d3e6c862a7
+SIZE (xpi/firefox-i18n-57.0/mk.xpi) = 490852
+SHA256 (xpi/firefox-i18n-57.0/ml.xpi) = a4be2963a72230143283d674ddcc3c28c5f09636524af145f5f53ecce0322572
+SIZE (xpi/firefox-i18n-57.0/ml.xpi) = 528255
+SHA256 (xpi/firefox-i18n-57.0/mr.xpi) = 410200d49c82a8ba5a0ecae914e1da3f04798506d9625acbc10c5ed3b99cec9d
+SIZE (xpi/firefox-i18n-57.0/mr.xpi) = 521289
+SHA256 (xpi/firefox-i18n-57.0/ms.xpi) = c1b61b1325581a5c2d927a675b19e9d2e34c708bbc45ce5f6c03f386de5b33e5
+SIZE (xpi/firefox-i18n-57.0/ms.xpi) = 451254
+SHA256 (xpi/firefox-i18n-57.0/my.xpi) = 512cb14ae373275c4755c478ac1dce4c51be15cde0b2aaaca5b29c3e45df0a5b
+SIZE (xpi/firefox-i18n-57.0/my.xpi) = 517702
+SHA256 (xpi/firefox-i18n-57.0/nb-NO.xpi) = a57311847934d5dcff18066ff7bd323f2c2406fa3df4c8e258b8d9d0939b1be8
+SIZE (xpi/firefox-i18n-57.0/nb-NO.xpi) = 451556
+SHA256 (xpi/firefox-i18n-57.0/nl.xpi) = 303f6a0b8379bbbd6db4ac45e6eb5397d725259ac67eec50a15b32686916d000
+SIZE (xpi/firefox-i18n-57.0/nl.xpi) = 458317
+SHA256 (xpi/firefox-i18n-57.0/nn-NO.xpi) = eb127fad8c44a4721fc1cf1d901d0c2aff16041b8bc54d2d3951b03bfac94600
+SIZE (xpi/firefox-i18n-57.0/nn-NO.xpi) = 452003
+SHA256 (xpi/firefox-i18n-57.0/or.xpi) = dc0f59099e8d0592b3e61d8d5c88ae22b9a1067fd89911b7799f8b43d13a2f6b
+SIZE (xpi/firefox-i18n-57.0/or.xpi) = 500863
+SHA256 (xpi/firefox-i18n-57.0/pa-IN.xpi) = 33348a739ae6b01c3629def78a855ea6ea816e0253b696e58ba9ccbff3fa37d6
+SIZE (xpi/firefox-i18n-57.0/pa-IN.xpi) = 495270
+SHA256 (xpi/firefox-i18n-57.0/pl.xpi) = fff4c80385e9eec79ec93d4fc35f84301fa28c8a527591196d719f675c9ffe2b
+SIZE (xpi/firefox-i18n-57.0/pl.xpi) = 364229
+SHA256 (xpi/firefox-i18n-57.0/pt-BR.xpi) = d50347c7a26681e87fe6b5978a8fc05f8d7a885ba440cc51da03b66875fbd76a
+SIZE (xpi/firefox-i18n-57.0/pt-BR.xpi) = 457153
+SHA256 (xpi/firefox-i18n-57.0/pt-PT.xpi) = b77f50f7b02a78dc24dc32e9bff82b46bf2e37a62f978c1fe5ac172f6bf63f26
+SIZE (xpi/firefox-i18n-57.0/pt-PT.xpi) = 459998
+SHA256 (xpi/firefox-i18n-57.0/rm.xpi) = 695b5483ecc003296cd25b0b441c73c73c475457466fd7cff3f39a8491a44910
+SIZE (xpi/firefox-i18n-57.0/rm.xpi) = 451057
+SHA256 (xpi/firefox-i18n-57.0/ro.xpi) = 591ecab4f6e3869da69e612f847a832a802050471655565d29aa8c76febe7b7e
+SIZE (xpi/firefox-i18n-57.0/ro.xpi) = 455509
+SHA256 (xpi/firefox-i18n-57.0/ru.xpi) = 3b7355af69378f3bf0642d8f93c2c1fb6a9665ddd5a2b6aec4865baa8cd7713f
+SIZE (xpi/firefox-i18n-57.0/ru.xpi) = 527005
+SHA256 (xpi/firefox-i18n-57.0/si.xpi) = 3392da245426ca4480b478455b61b6d53fe5741e7c0c3772a610e622b0248715
+SIZE (xpi/firefox-i18n-57.0/si.xpi) = 498323
+SHA256 (xpi/firefox-i18n-57.0/sk.xpi) = 5ac2035fdb85fb5bb789b6f2723e69bd23e6a15f6a4dfb184c08100aafead6ba
+SIZE (xpi/firefox-i18n-57.0/sk.xpi) = 480395
+SHA256 (xpi/firefox-i18n-57.0/sl.xpi) = 6c55623bb30635ac67abcd3fab3b4cc30de5fefea2ae0bbb99f15be7c7843245
+SIZE (xpi/firefox-i18n-57.0/sl.xpi) = 459376
+SHA256 (xpi/firefox-i18n-57.0/son.xpi) = ac13a973cacd9e4c84401cd11095c0a0f307d07ebb0719174adcfcf957188316
+SIZE (xpi/firefox-i18n-57.0/son.xpi) = 450929
+SHA256 (xpi/firefox-i18n-57.0/sq.xpi) = 2b999472e0e6550b63782d15aa713bac47b3ddcf8a212673a30fd6e55090215c
+SIZE (xpi/firefox-i18n-57.0/sq.xpi) = 465050
+SHA256 (xpi/firefox-i18n-57.0/sr.xpi) = 75849a57f9b44b73445b302279dcb626389670a20dc3a404ad5db774c3ceaa00
+SIZE (xpi/firefox-i18n-57.0/sr.xpi) = 487002
+SHA256 (xpi/firefox-i18n-57.0/sv-SE.xpi) = 87ec5cbe45db203cfd1fd49ab7d2fb78df72fdcd4867e2dcc16727463100bb06
+SIZE (xpi/firefox-i18n-57.0/sv-SE.xpi) = 459664
+SHA256 (xpi/firefox-i18n-57.0/ta.xpi) = 74382122b90dbd76d128d5a860d40ddc839f315ee7cecbcdb73c2fbf20169199
+SIZE (xpi/firefox-i18n-57.0/ta.xpi) = 513225
+SHA256 (xpi/firefox-i18n-57.0/te.xpi) = a40de1d2174392d96bda8cfe65c8e374f4c833add0e1719d6c44616b571e6855
+SIZE (xpi/firefox-i18n-57.0/te.xpi) = 530692
+SHA256 (xpi/firefox-i18n-57.0/th.xpi) = 9d7cff5544312d33d44a2728f095e095e646ae2cd904e014fe69ca8016440884
+SIZE (xpi/firefox-i18n-57.0/th.xpi) = 502450
+SHA256 (xpi/firefox-i18n-57.0/tr.xpi) = fa1e8613954cae82fa460eb840af561df5857320a33ec5a1f8b032e3ed558dee
+SIZE (xpi/firefox-i18n-57.0/tr.xpi) = 465580
+SHA256 (xpi/firefox-i18n-57.0/uk.xpi) = b477818ae7061f7523625380e93fbe9bdfc385279e7e96cb06e98e6ed5915d86
+SIZE (xpi/firefox-i18n-57.0/uk.xpi) = 518137
+SHA256 (xpi/firefox-i18n-57.0/ur.xpi) = d9b3f9e18241a5abb31906792bae33c6b6b579631678c97236291e388e8bc195
+SIZE (xpi/firefox-i18n-57.0/ur.xpi) = 511133
+SHA256 (xpi/firefox-i18n-57.0/uz.xpi) = 4d4fe1f56e5c86f779753eed44f1b5d3f1cceb3a6f46950d175ed31c9f7ff39d
+SIZE (xpi/firefox-i18n-57.0/uz.xpi) = 461693
+SHA256 (xpi/firefox-i18n-57.0/vi.xpi) = ce81dbf85ddd901acb8c9cf7cfd331d2dfe6f4a7f5e4d799d664ff867bd5d40b
+SIZE (xpi/firefox-i18n-57.0/vi.xpi) = 471319
+SHA256 (xpi/firefox-i18n-57.0/xh.xpi) = be4d359e06a8a10cfda658a6e7c1e13ff857fd767d76882bedfd1aada3a6900c
+SIZE (xpi/firefox-i18n-57.0/xh.xpi) = 464460
+SHA256 (xpi/firefox-i18n-57.0/zh-CN.xpi) = 040736b596b614e55ac09aefa3e9f04211f16cb257ea0c2d274ca0df99b787b6
+SIZE (xpi/firefox-i18n-57.0/zh-CN.xpi) = 483624
+SHA256 (xpi/firefox-i18n-57.0/zh-TW.xpi) = fa5cf52246a289bc91d60519697977cbd6f999f5bda7eb715cb8303af543b752
+SIZE (xpi/firefox-i18n-57.0/zh-TW.xpi) = 482346
diff --git a/www/firefox/Makefile b/www/firefox/Makefile
index 04fa398418a4..54dbd5b180b2 100644
--- a/www/firefox/Makefile
+++ b/www/firefox/Makefile
@@ -2,27 +2,26 @@
# $FreeBSD$
PORTNAME= firefox
-DISTVERSION= 56.0.2
+DISTVERSION= 57.0
DISTVERSIONSUFFIX=.source
-PORTREVISION= 10
PORTEPOCH= 1
CATEGORIES= www ipv6
MASTER_SITES= MOZILLA/${PORTNAME}/releases/${DISTVERSION}/source \
- MOZILLA/${PORTNAME}/candidates/${DISTVERSION}-candidates/build1/source
+ MOZILLA/${PORTNAME}/candidates/${DISTVERSION}-candidates/build4/source
MAINTAINER= gecko@FreeBSD.org
COMMENT= Web browser based on the browser portion of Mozilla
-BUILD_DEPENDS= nspr>=4.16:devel/nspr \
- nss>=3.32.1:security/nss \
+BUILD_DEPENDS= nspr>=4.17:devel/nspr \
+ nss>=3.33:security/nss \
icu>=59.1,1:devel/icu \
libevent>=2.1.8:devel/libevent \
- harfbuzz>=1.4.7:print/harfbuzz \
+ harfbuzz>=1.5.1:print/harfbuzz \
graphite2>=1.3.10:graphics/graphite2 \
png>=1.6.31:graphics/png \
libvorbis>=1.3.5,3:audio/libvorbis \
libvpx>=1.5.0:multimedia/libvpx \
- sqlite3>=3.19.3:databases/sqlite3 \
+ sqlite3>=3.20.1:databases/sqlite3 \
${PYTHON_PKGNAMEPREFIX}sqlite3>0:databases/py-sqlite3 \
v4l_compat>0:multimedia/v4l_compat \
autoconf-2.13:devel/autoconf213 \
diff --git a/www/firefox/distinfo b/www/firefox/distinfo
index 1294136080e5..75a618aa0883 100644
--- a/www/firefox/distinfo
+++ b/www/firefox/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1508873487
-SHA256 (firefox-56.0.2.source.tar.xz) = 6f7d284c31383a9860d7b52f05f866526d5a7c31e3ef2959d79122ba074f5ca1
-SIZE (firefox-56.0.2.source.tar.xz) = 255658916
+TIMESTAMP = 1510498738
+SHA256 (firefox-57.0.source.tar.xz) = 603af00155be87f2c9c58047dd0072971f1cdab1f632695aae6ad072efefbb8f
+SIZE (firefox-57.0.source.tar.xz) = 250728772
diff --git a/www/firefox/files/patch-a-bug1399540 b/www/firefox/files/patch-a-bug1399540
deleted file mode 100644
index 9ccdeec6c94e..000000000000
--- a/www/firefox/files/patch-a-bug1399540
+++ /dev/null
@@ -1,148 +0,0 @@
-commit 99ad73e4743d
-Author: Jonathan Kew <jkew@mozilla.com>
-Date: Sat Sep 16 11:49:47 2017 +0100
-
- Bug 1399540 - patch 1 - Failure to decode an individual label within the IDN should not block decoding of other valid punycode labels. r=valentin
----
- netwerk/dns/nsIDNService.cpp | 25 ++++++++++++++++---------
- 1 file changed, 16 insertions(+), 9 deletions(-)
-
-diff --git netwerk/dns/nsIDNService.cpp netwerk/dns/nsIDNService.cpp
-index 9cc8fdcf6fa1..3adcddf654e1 100644
---- netwerk/dns/nsIDNService.cpp
-+++ netwerk/dns/nsIDNService.cpp
-@@ -300,6 +300,10 @@ nsresult nsIDNService::ACEtoUTF8(const nsACString & input, nsACString & _retval,
- // RFC 3490 - 4.2 ToUnicode
- // ToUnicode never fails. If any step fails, then the original input
- // sequence is returned immediately in that step.
-+ //
-+ // Note that this refers to the decoding of a single label.
-+ // ACEtoUTF8 may be called with a sequence of labels separated by dots;
-+ // this test applies individually to each label.
-
- uint32_t len = 0, offset = 0;
- nsAutoCString decodedBuf;
-@@ -313,13 +317,15 @@ nsresult nsIDNService::ACEtoUTF8(const nsACString & input, nsACString & _retval,
- while (start != end) {
- len++;
- if (*start++ == '.') {
-- if (NS_FAILED(decodeACE(Substring(input, offset, len - 1), decodedBuf,
-- flag))) {
-- _retval.Assign(input);
-- return NS_OK;
-+ nsDependentCSubstring origLabel(input, offset, len - 1);
-+ if (NS_FAILED(decodeACE(origLabel, decodedBuf, flag))) {
-+ // If decoding failed, use the original input sequence
-+ // for this label.
-+ _retval.Append(origLabel);
-+ } else {
-+ _retval.Append(decodedBuf);
- }
-
-- _retval.Append(decodedBuf);
- _retval.Append('.');
- offset += len;
- len = 0;
-@@ -327,11 +333,12 @@ nsresult nsIDNService::ACEtoUTF8(const nsACString & input, nsACString & _retval,
- }
- // decode the last node
- if (len) {
-- if (NS_FAILED(decodeACE(Substring(input, offset, len), decodedBuf,
-- flag)))
-- _retval.Assign(input);
-- else
-+ nsDependentCSubstring origLabel(input, offset, len);
-+ if (NS_FAILED(decodeACE(origLabel, decodedBuf, flag))) {
-+ _retval.Append(origLabel);
-+ } else {
- _retval.Append(decodedBuf);
-+ }
- }
-
- return NS_OK;
-
-commit eddd7a4f4eae
-Author: Jonathan Kew <jkew@mozilla.com>
-Date: Sat Sep 16 11:49:56 2017 +0100
-
- Bug 1399540 - patch 2 - Handle invalid punycode better in stringPrep to avoid mangling display of fake-punycode labels. r=valentin
----
- netwerk/dns/nsIDNService.cpp | 10 +++++++++-
- 1 file changed, 9 insertions(+), 1 deletion(-)
-
-diff --git netwerk/dns/nsIDNService.cpp netwerk/dns/nsIDNService.cpp
-index 3adcddf654e1..4c45a2d52e45 100644
---- netwerk/dns/nsIDNService.cpp
-+++ netwerk/dns/nsIDNService.cpp
-@@ -222,7 +222,15 @@ nsIDNService::IDNA2008StringPrep(const nsAString& input,
- }
- NS_ENSURE_SUCCESS(rv, rv);
-
-- // Output the result of nameToUnicode even if there were errors
-+ // Output the result of nameToUnicode even if there were errors.
-+ // But in the case of invalid punycode, the uidna_labelToUnicode result
-+ // appears to get an appended U+FFFD REPLACEMENT CHARACTER, which will
-+ // confuse our subsequent processing, so we drop that.
-+ // (https://bugzilla.mozilla.org/show_bug.cgi?id=1399540#c9)
-+ if ((info.errors & UIDNA_ERROR_PUNYCODE) &&
-+ outLen > 0 && outputBuffer[outLen - 1] == 0xfffd) {
-+ --outLen;
-+ }
- ICUUtils::AssignUCharArrayToString(outputBuffer, outLen, output);
-
- if (flag == eStringPrepIgnoreErrors) {
-
-commit 2a3883ef55d2
-Author: Jonathan Kew <jkew@mozilla.com>
-Date: Sat Sep 16 11:50:08 2017 +0100
-
- Bug 1399540 - Add some IDN testcases with mixed punycode and non-punycode labels. r=valentin
----
- netwerk/test/unit/test_idn_urls.js | 25 ++++++++++++++++---------
- 1 file changed, 16 insertions(+), 9 deletions(-)
-
-diff --git netwerk/test/unit/test_idn_urls.js netwerk/test/unit/test_idn_urls.js
-index 358854093f65..0d8cf3216293 100644
---- netwerk/test/unit/test_idn_urls.js
-+++ netwerk/test/unit/test_idn_urls.js
-@@ -286,10 +286,17 @@ const testcases = [
- // Thai (also tests that node with over 63 UTF-8 octets doesn't fail)
- ["เครื่องทําน้ําทําน้ําแข็ง",
- "xn--22cdjb2fanb9fyepcbbb9dwh4a3igze4fdcd",
-- false, true, true]
-+ false, true, true],
-+
-+ // Effect of adding valid or invalid subdomains (bug 1399540)
-+ ["䕮䕵䕶䕱.ascii", "xn--google.ascii", false, true, true],
-+ ["ascii.䕮䕵䕶䕱", "ascii.xn--google", false, true, true],
-+ ["中国123.䕮䕵䕶䕱", "xn--123-u68dy61b.xn--google", false, true, true],
-+ ["䕮䕵䕶䕱.中国123", "xn--google.xn--123-u68dy61b", false, true, true],
-+ ["xn--accountlogin.䕮䕵䕶䕱", "xn--accountlogin.xn--google", false, true, true],
-+ ["䕮䕵䕶䕱.xn--accountlogin", "xn--google.xn--accountlogin", false, true, true],
- ];
-
--
- const profiles = ["ASCII", "high", "moderate"];
-
- function run_test() {
-@@ -311,13 +318,13 @@ function run_test() {
- var expectedUnicode = test[2 + i];
- var isASCII = {};
-
-- var result;
-- try {
-- result = idnService.convertToDisplayIDN(URL, isASCII);
-- } catch(e) {
-- result = ".com";
-- }
-- if (punycodeURL.substr(0, 4) == "xn--") {
-+ var result;
-+ try {
-+ result = idnService.convertToDisplayIDN(URL, isASCII);
-+ } catch(e) {
-+ result = ".com";
-+ }
-+ if (punycodeURL.substr(0, 4) == "xn--" || punycodeURL.indexOf(".xn--") > 0) {
- // test convertToDisplayIDN with a Unicode URL and with a
- // Punycode URL if we have one
- do_check_eq(escape(result),
diff --git a/www/firefox/files/patch-bug1261175 b/www/firefox/files/patch-bug1261175
deleted file mode 100644
index 527f41b4a0b3..000000000000
--- a/www/firefox/files/patch-bug1261175
+++ /dev/null
@@ -1,25 +0,0 @@
-commit deccfad4c8ba
-Author: Matt Woodrow <mwoodrow@mozilla.com>
-Date: Thu Oct 12 13:10:27 2017 +1300
-
- Bug 1261175. r=tnikkel, a=ritu
-
- --HG--
- extra : source : 8281ed36bd4946af69af747b199814cc1a51fb52
----
- view/nsViewManager.cpp | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git view/nsViewManager.cpp view/nsViewManager.cpp
-index f3540f3478da..230512c0dcc0 100644
---- view/nsViewManager.cpp
-+++ view/nsViewManager.cpp
-@@ -100,7 +100,7 @@ nsViewManager::~nsViewManager()
- gViewManagers = nullptr;
- }
-
-- mPresShell = nullptr;
-+ MOZ_RELEASE_ASSERT(!mPresShell, "Releasing nsViewManager without having called Destroy on the PresShell!");
- }
-
- // We don't hold a reference to the presentation context because it
diff --git a/www/firefox/files/patch-bug1325923 b/www/firefox/files/patch-bug1325923
deleted file mode 100644
index 0741e2d6c56f..000000000000
--- a/www/firefox/files/patch-bug1325923
+++ /dev/null
@@ -1,121 +0,0 @@
-commit d9ad239a35bf
-Author: Blake Kaplan <mrbkap@gmail.com>
-Date: Wed Aug 16 16:39:32 2017 -0700
-
- Bug 1325923 - Implement the "cookie averse document" concept. r=Ehsan
-
- See https://html.spec.whatwg.org/multipage/dom.html#resource-metadata-management:cookie-averse-document-object
-
- MozReview-Commit-ID: GndxqhU77cS
----
- dom/base/nsIDocument.h | 28 ++++++++++++++++++++++++++++
- 1 file changed, 28 insertions(+)
-
-diff --git dom/base/nsIDocument.h dom/base/nsIDocument.h
-index e834f5785cad..921e03e107d1 100644
---- dom/base/nsIDocument.h
-+++ dom/base/nsIDocument.h
-@@ -2073,6 +2073,34 @@ public:
- return mMarkedCCGeneration;
- }
-
-+ /**
-+ * Returns whether this document is cookie averse. See
-+ * https://html.spec.whatwg.org/multipage/dom.html#cookie-averse-document-object
-+ */
-+ bool IsCookieAverse() const
-+ {
-+ // If we are a document that "has no browsing context."
-+ if (!GetInnerWindow()) {
-+ return true;
-+ }
-+
-+ // If we are a document "whose URL's scheme is not a network scheme."
-+ // NB: Explicitly allow file: URIs to store cookies.
-+ nsCOMPtr<nsIURI> codebaseURI;
-+ NodePrincipal()->GetURI(getter_AddRefs(codebaseURI));
-+
-+ if (!codebaseURI) {
-+ return true;
-+ }
-+
-+ nsAutoCString scheme;
-+ codebaseURI->GetScheme(scheme);
-+ return !scheme.EqualsLiteral("http") &&
-+ !scheme.EqualsLiteral("https") &&
-+ !scheme.EqualsLiteral("ftp") &&
-+ !scheme.EqualsLiteral("file");
-+ }
-+
- bool IsLoadedAsData()
- {
- return mLoadedAsData;
-
-commit 10775852824c
-Author: Blake Kaplan <mrbkap@gmail.com>
-Date: Wed Aug 16 16:58:19 2017 -0700
-
- Bug 1325923 - Use this new API. r=Ehsan
-
- MozReview-Commit-ID: 6tuaEqQA551
----
- dom/base/nsContentSink.cpp | 6 ++++++
- 1 file changed, 6 insertions(+)
-
-diff --git dom/base/nsContentSink.cpp dom/base/nsContentSink.cpp
-index c52761c8521f..c3e9f43846d4 100644
---- dom/base/nsContentSink.cpp
-+++ dom/base/nsContentSink.cpp
-@@ -843,6 +843,12 @@ nsContentSink::ProcessMETATag(nsIContent* aContent)
- return NS_OK;
- }
-
-+ // Don't allow setting cookies in <meta http-equiv> in cookie averse
-+ // documents.
-+ if (nsGkAtoms::setcookie->Equals(header) && mDocument->IsCookieAverse()) {
-+ return NS_OK;
-+ }
-+
- nsAutoString result;
- aContent->GetAttr(kNameSpaceID_None, nsGkAtoms::content, result);
- if (!result.IsEmpty()) {
-
-commit f48bc2cbf262
-Author: Blake Kaplan <mrbkap@gmail.com>
-Date: Wed Aug 16 17:22:31 2017 -0700
-
- Bug 1325923 - Use this API where we're supposed to. r=Ehsan
-
- MozReview-Commit-ID: HGU5YtUzv9U
----
- dom/html/nsHTMLDocument.cpp | 10 ++++++++++
- 1 file changed, 10 insertions(+)
-
-diff --git dom/html/nsHTMLDocument.cpp dom/html/nsHTMLDocument.cpp
-index fa3d614854d9..b146698b6494 100644
---- dom/html/nsHTMLDocument.cpp
-+++ dom/html/nsHTMLDocument.cpp
-@@ -1347,6 +1347,11 @@ nsHTMLDocument::GetCookie(nsAString& aCookie, ErrorResult& rv)
- return;
- }
-
-+ // If the document is a cookie-averse Document... return the empty string.
-+ if (IsCookieAverse()) {
-+ return;
-+ }
-+
- // not having a cookie service isn't an error
- nsCOMPtr<nsICookieService> service = do_GetService(NS_COOKIESERVICE_CONTRACTID);
- if (service) {
-@@ -1400,6 +1405,11 @@ nsHTMLDocument::SetCookie(const nsAString& aCookie, ErrorResult& rv)
- return;
- }
-
-+ // If the document is a cookie-averse Document... do nothing.
-+ if (IsCookieAverse()) {
-+ return;
-+ }
-+
- // not having a cookie service isn't an error
- nsCOMPtr<nsICookieService> service = do_GetService(NS_COOKIESERVICE_CONTRACTID);
- if (service && mDocumentURI) {
diff --git a/www/firefox/files/patch-bug1343147 b/www/firefox/files/patch-bug1343147
deleted file mode 100644
index a548c655e4dc..000000000000
--- a/www/firefox/files/patch-bug1343147
+++ /dev/null
@@ -1,117 +0,0 @@
-commit e215b167b9b9
-Author: cku <cku@mozilla.com>
-Date: Tue Oct 3 11:29:19 2017 +0800
-
- Bug 1343147 - Do not double applying transform vector of the root frame in a glyph mask into the target context. r=mstange, a=ritu
-
- When we generate the glyph mask for a transformed frame in
- GenerateAndPushTextMask, the transform vector had been applied into aContext[1],
- so we should find a way to prevent applying the vector again when painting the
- glyph mask.
-
- In bug 1299715, I tried to prevent double apply at [2], it caused two problems:
- 1. We only skip generating nsDisplayTransform, but we may still create a
- nsDisplayPerspactive bellow. Since the parent of a nsDisplayPerspective must be
- a nsDisplayTransform, which have been ignored, so we hit this assertion.
- 2. We skip all transform for all frames while painting the glyph mask, which is
- not correct. We should only skip double applying transform vector of the root
- frame.
-
- This patch fixes both of these issues:
- a. We will still create a nsDisplayTransform for the root frame if need. But
- the transform matrix we apply into the target context will be an identity
- matrix, so we fix #1 above.
- b. In #a, we change the transform matrix to an identity matrix only for the root
- frame of the glyph mask, so we fix #2.
-
- [1]
- https://hg.mozilla.org/mozilla-central/file/59e5ec5729db/layout/painting/nsDisplayList.cpp#l752
- [2]
- https://hg.mozilla.org/mozilla-central/file/ce2c129f0a87/layout/generic/nsFrame.cpp#l2806
-
- MozReview-Commit-ID: 973lkQQxLB6
-
- --HG--
- extra : source : 84451d723686bc47b81c44ed2ddf6c61f3e35915
----
- layout/generic/nsFrame.cpp | 13 +++++--------
- layout/painting/nsDisplayList.cpp | 9 ++++++++-
- 2 files changed, 13 insertions(+), 9 deletions(-)
-
-diff --git layout/generic/nsFrame.cpp layout/generic/nsFrame.cpp
-index 37f2e2801220..dbfd61b7e142 100644
---- layout/generic/nsFrame.cpp
-+++ layout/generic/nsFrame.cpp
-@@ -2803,14 +2803,11 @@ nsIFrame::BuildDisplayListForStackingContext(nsDisplayListBuilder* aBuilder,
- buildingDisplayList.SetReferenceFrameAndCurrentOffset(outerReferenceFrame,
- GetOffsetToCrossDoc(outerReferenceFrame));
-
-- if (!aBuilder->IsForGenerateGlyphMask() &&
-- !aBuilder->IsForPaintingSelectionBG()) {
-- nsDisplayTransform *transformItem =
-- new (aBuilder) nsDisplayTransform(aBuilder, this,
-- &resultList, dirtyRect, 0,
-- allowAsyncAnimation);
-- resultList.AppendNewToTop(transformItem);
-- }
-+ nsDisplayTransform *transformItem =
-+ new (aBuilder) nsDisplayTransform(aBuilder, this,
-+ &resultList, dirtyRect, 0,
-+ allowAsyncAnimation);
-+ resultList.AppendNewToTop(transformItem);
-
- if (hasPerspective) {
- if (clipCapturedBy == ContainerItemType::ePerspective) {
-diff --git layout/painting/nsDisplayList.cpp layout/painting/nsDisplayList.cpp
-index 801e1ea2fb4d..6477bda52f01 100644
---- layout/painting/nsDisplayList.cpp
-+++ layout/painting/nsDisplayList.cpp
-@@ -7976,11 +7976,18 @@ already_AddRefed<Layer> nsDisplayTransform::BuildLayer(nsDisplayListBuilder *aBu
- LayerManager *aManager,
- const ContainerLayerParameters& aContainerParameters)
- {
-+ // While generating a glyph mask, the transform vector of the root frame had
-+ // been applied into the target context, so stop applying it again here.
-+ const bool shouldSkipTransform =
-+ (aBuilder->RootReferenceFrame() == mFrame) &&
-+ (aBuilder->IsForGenerateGlyphMask() || aBuilder->IsForPaintingSelectionBG());
-+
- /* For frames without transform, it would not be removed for
- * backface hidden here. But, it would be removed by the init
- * function of nsDisplayTransform.
- */
-- const Matrix4x4& newTransformMatrix = GetTransformForRendering();
-+ const Matrix4x4 newTransformMatrix =
-+ shouldSkipTransform ? Matrix4x4(): GetTransformForRendering();
-
- uint32_t flags = FrameLayerBuilder::CONTAINER_ALLOW_PULL_BACKGROUND_COLOR;
- RefPtr<ContainerLayer> container = aManager->GetLayerBuilder()->
-diff --git dom/svg/crashtests/1343147.svg dom/svg/crashtests/1343147.svg
-new file mode 100644
-index 000000000000..d9c2611ca822
---- /dev/null
-+++ dom/svg/crashtests/1343147.svg
-@@ -0,0 +1,13 @@
-+<svg xmlns="http://www.w3.org/2000/svg">
-+<style>
-+<![CDATA[
-+ svg {
-+ background-image: linear-gradient(lime, lime);
-+ background-clip: text;
-+ }
-+ text { transform: skewy(30grad); }
-+ g { perspective: 0; }
-+]]>
-+</style>
-+ <g><text>hello</text></g>
-+</svg>
-diff --git dom/svg/crashtests/crashtests.list dom/svg/crashtests/crashtests.list
-index 1727a206ec4f..57ab320161e2 100644
---- dom/svg/crashtests/crashtests.list
-+++ dom/svg/crashtests/crashtests.list
-@@ -90,4 +90,5 @@ load 1329849-5.svg
- load 1329849-6.svg
- load 1329093-1.html
- load 1329093-2.html
-+load 1343147.svg
- load 1402798.html
diff --git a/www/firefox/files/patch-bug1355576 b/www/firefox/files/patch-bug1355576
deleted file mode 100644
index cc9c8236a2b4..000000000000
--- a/www/firefox/files/patch-bug1355576
+++ /dev/null
@@ -1,262 +0,0 @@
-commit e530ba4d4394
-Author: Thomas Wisniewski <wisniewskit@gmail.com>
-Date: Tue Jul 4 20:59:26 2017 -0400
-
- Bug 1355576 - Add ability to clear all localStorage with the browsingData API; r=bsilverberg,janv
-
- MozReview-Commit-ID: 4UUqg62yIo9
-
- --HG--
- extra : rebase_source : 9c6154bbe878fc3921d22027fdc90dbdaed05be9
----
- browser/components/extensions/ext-browsingData.js | 10 +++
- .../extensions/schemas/browsing_data.json | 1 -
- .../extensions/test/browser/browser-common.ini | 1 +
- .../browser_ext_browsingData_localStorage.js | 93 ++++++++++++++++++++++
- .../test/xpcshell/test_ext_browsingData.js | 4 +-
- dom/storage/LocalStorageManager.cpp | 3 +-
- dom/storage/StorageObserver.cpp | 12 +++
- .../extensions/schemas/browsing_data.json | 1 -
- 8 files changed, 120 insertions(+), 5 deletions(-)
-
-diff --git browser/components/extensions/ext-browsingData.js browser/components/extensions/ext-browsingData.js
-index fd59141dd15d..109ec9601487 100644
---- browser/components/extensions/ext-browsingData.js
-+++ browser/components/extensions/ext-browsingData.js
-@@ -83,6 +83,10 @@ const clearHistory = options => {
- return sanitizer.items.history.clear(makeRange(options));
- };
-
-+const clearLocalStorage = async function(options) {
-+ Services.obs.notifyObservers(null, "extension:purge-localStorage");
-+};
-+
- const clearPasswords = async function(options) {
- let loginManager = Services.logins;
- let yieldCounter = 0;
-@@ -152,6 +156,9 @@ const doRemoval = (options, dataToRemove, extension) => {
- case "history":
- removalPromises.push(clearHistory(options));
- break;
-+ case "localStorage":
-+ removalPromises.push(clearLocalStorage(options));
-+ break;
- case "passwords":
- removalPromises.push(clearPasswords(options));
- break;
-@@ -225,6 +232,9 @@ this.browsingData = class extends ExtensionAPI {
- removeHistory(options) {
- return doRemoval(options, {history: true});
- },
-+ removeLocalStorage(options) {
-+ return doRemoval(options, {localStorage: true});
-+ },
- removePasswords(options) {
- return doRemoval(options, {passwords: true});
- },
-diff --git browser/components/extensions/schemas/browsing_data.json browser/components/extensions/schemas/browsing_data.json
-index a780f5640c8f..7755714eb898 100644
---- browser/components/extensions/schemas/browsing_data.json
-+++ browser/components/extensions/schemas/browsing_data.json
-@@ -341,7 +341,6 @@
- "description": "Clears websites' local storage data.",
- "type": "function",
- "async": "callback",
-- "unsupported": true,
- "parameters": [
- {
- "$ref": "RemovalOptions",
-diff --git browser/components/extensions/test/browser/browser-common.ini browser/components/extensions/test/browser/browser-common.ini
-index 464b8ba18f37..e3f7700f3939 100644
---- browser/components/extensions/test/browser/browser-common.ini
-+++ browser/components/extensions/test/browser/browser-common.ini
-@@ -46,6 +46,7 @@ skip-if = (os == 'win' && !debug) # bug 1352668
- [browser_ext_browserAction_theme_icons.js]
- [browser_ext_browsingData_formData.js]
- [browser_ext_browsingData_history.js]
-+[browser_ext_browsingData_localStorage.js]
- [browser_ext_browsingData_pluginData.js]
- [browser_ext_browsingData_serviceWorkers.js]
- [browser_ext_commands_execute_browser_action.js]
-diff --git browser/components/extensions/test/browser/browser_ext_browsingData_localStorage.js browser/components/extensions/test/browser/browser_ext_browsingData_localStorage.js
-new file mode 100644
-index 000000000000..215f26d1fcb6
---- /dev/null
-+++ browser/components/extensions/test/browser/browser_ext_browsingData_localStorage.js
-@@ -0,0 +1,93 @@
-+/* -*- Mode: indent-tabs-mode: nil; js-indent-level: 2 -*- */
-+/* vim: set sts=2 sw=2 et tw=80: */
-+"use strict";
-+
-+add_task(async function testLocalStorage() {
-+ async function background() {
-+ function openTabs() {
-+ let promise = new Promise(resolve => {
-+ let tabURLs = [
-+ "http://example.com/",
-+ "http://example.net/",
-+ ];
-+
-+ let tabs;
-+ let waitingCount = tabURLs.length;
-+
-+ let listener = async msg => {
-+ if (msg !== "content-script-ready" || --waitingCount) {
-+ return;
-+ }
-+ browser.runtime.onMessage.removeListener(listener);
-+ resolve(Promise.all(tabs));
-+ };
-+
-+ browser.runtime.onMessage.addListener(listener);
-+
-+ tabs = tabURLs.map(url => {
-+ return browser.tabs.create({url: url});
-+ });
-+ });
-+
-+ return promise;
-+ }
-+
-+ function sendMessageToTabs(tabs, message) {
-+ return Promise.all(
-+ tabs.map(tab => { return browser.tabs.sendMessage(tab.id, message); }));
-+ }
-+
-+ let tabs = await openTabs();
-+
-+ await sendMessageToTabs(tabs, "resetLocalStorage");
-+ await sendMessageToTabs(tabs, "checkLocalStorageSet");
-+ await browser.browsingData.removeLocalStorage({});
-+ await sendMessageToTabs(tabs, "checkLocalStorageCleared");
-+
-+ await sendMessageToTabs(tabs, "resetLocalStorage");
-+ await sendMessageToTabs(tabs, "checkLocalStorageSet");
-+ await browser.browsingData.remove({}, {localStorage: true});
-+ await sendMessageToTabs(tabs, "checkLocalStorageCleared");
-+
-+ browser.tabs.remove(tabs.map(tab => tab.id));
-+
-+ browser.test.notifyPass("done");
-+ }
-+
-+ function contentScript() {
-+ browser.runtime.onMessage.addListener(msg => {
-+ if (msg === "resetLocalStorage") {
-+ localStorage.clear();
-+ localStorage.setItem("test", "test");
-+ } else if (msg === "checkLocalStorageSet") {
-+ browser.test.assertEq("test", localStorage.getItem("test"));
-+ } else if (msg === "checkLocalStorageCleared") {
-+ browser.test.assertEq(null, localStorage.getItem("test"));
-+ }
-+ });
-+ browser.runtime.sendMessage("content-script-ready");
-+ }
-+
-+ let extension = ExtensionTestUtils.loadExtension({
-+ background,
-+ manifest: {
-+ "permissions": ["browsingData"],
-+ "content_scripts": [{
-+ "matches": [
-+ "http://example.com/",
-+ "http://example.net/",
-+ ],
-+ "js": ["content-script.js"],
-+ "run_at": "document_start",
-+ }],
-+ },
-+ files: {
-+ "content-script.js": contentScript,
-+ },
-+ });
-+
-+ await extension.startup();
-+ await extension.awaitFinish("done");
-+ await extension.unload();
-+});
-+
-diff --git browser/components/extensions/test/xpcshell/test_ext_browsingData.js browser/components/extensions/test/xpcshell/test_ext_browsingData.js
-index 0c1c4874ca44..0b8972058e64 100644
---- browser/components/extensions/test/xpcshell/test_ext_browsingData.js
-+++ browser/components/extensions/test/xpcshell/test_ext_browsingData.js
-@@ -44,7 +44,7 @@ add_task(async function testInvalidArguments() {
-
- add_task(async function testUnimplementedDataType() {
- function background() {
-- browser.browsingData.remove({}, {localStorage: true});
-+ browser.browsingData.remove({}, {indexedDB: true});
- browser.test.sendMessage("finished");
- }
-
-@@ -61,6 +61,6 @@ add_task(async function testUnimplementedDataType() {
- await extension.unload();
- });
-
-- let warningObserved = messages.find(line => /Firefox does not support dataTypes: localStorage/.test(line));
-+ let warningObserved = messages.find(line => /Firefox does not support dataTypes: indexedDB/.test(line));
- ok(warningObserved, "Warning issued when calling remove with an unimplemented dataType.");
- });
-diff --git dom/storage/LocalStorageManager.cpp dom/storage/LocalStorageManager.cpp
-index a161de2bc596..f366e7874a90 100644
---- dom/storage/LocalStorageManager.cpp
-+++ dom/storage/LocalStorageManager.cpp
-@@ -386,7 +386,8 @@ LocalStorageManager::Observe(const char* aTopic,
- }
-
- // Clear everything, caches + database
-- if (!strcmp(aTopic, "cookie-cleared")) {
-+ if (!strcmp(aTopic, "cookie-cleared") ||
-+ !strcmp(aTopic, "extension:purge-localStorage-caches")) {
- ClearCaches(LocalStorageCache::kUnloadComplete, pattern, EmptyCString());
- return NS_OK;
- }
-diff --git dom/storage/StorageObserver.cpp dom/storage/StorageObserver.cpp
-index e5b010f88c7b..48d484748209 100644
---- dom/storage/StorageObserver.cpp
-+++ dom/storage/StorageObserver.cpp
-@@ -66,6 +66,7 @@ StorageObserver::Init()
- obs->AddObserver(sSelf, "browser:purge-domain-data", true);
- obs->AddObserver(sSelf, "last-pb-context-exited", true);
- obs->AddObserver(sSelf, "clear-origin-attributes-data", true);
-+ obs->AddObserver(sSelf, "extension:purge-localStorage", true);
-
- // Shutdown
- obs->AddObserver(sSelf, "profile-after-change", true);
-@@ -270,6 +271,23 @@ StorageObserver::Observe(nsISupports* aSubject,
-
- Notify("session-only-cleared", NS_ConvertUTF8toUTF16(originSuffix),
- originScope);
-+
-+ return NS_OK;
-+ }
-+
-+ if (!strcmp(aTopic, "extension:purge-localStorage")) {
-+ StorageDBChild* storageChild = StorageDBChild::GetOrCreate();
-+ if (NS_WARN_IF(!storageChild)) {
-+ return NS_ERROR_FAILURE;
-+ }
-+
-+ storageChild->AsyncClearAll();
-+
-+ if (XRE_IsParentProcess()) {
-+ storageChild->SendClearAll();
-+ }
-+
-+ Notify("extension:purge-localStorage-caches");
-
- return NS_OK;
- }
-diff --git mobile/android/components/extensions/schemas/browsing_data.json mobile/android/components/extensions/schemas/browsing_data.json
-index 483a462d422c..1019c1a23953 100644
---- mobile/android/components/extensions/schemas/browsing_data.json
-+++ mobile/android/components/extensions/schemas/browsing_data.json
-@@ -345,7 +345,6 @@
- "description": "Clears websites' local storage data.",
- "type": "function",
- "async": "callback",
-- "unsupported": true,
- "parameters": [
- {
- "$ref": "RemovalOptions",
diff --git a/www/firefox/files/patch-bug1365894 b/www/firefox/files/patch-bug1365894
deleted file mode 100644
index 8dc1020ad37f..000000000000
--- a/www/firefox/files/patch-bug1365894
+++ /dev/null
@@ -1,60 +0,0 @@
-commit 97515a9302ed
-Author: James Cheng <jacheng@mozilla.com>
-Date: Mon Oct 9 13:40:12 2017 -0400
-
- Bug 1365894 - Make SystemGroupImpl be a normal ref-counted object. r=ehsan, a=ritu
-
- MozReview-Commit-ID: LUcoBhNx2M5
-
- --HG--
- extra : source : 3959033a31666770047dd460979032464a48ba66
----
- xpcom/threads/SystemGroup.cpp | 18 +++++-------------
- 1 file changed, 5 insertions(+), 13 deletions(-)
-
-diff --git xpcom/threads/SystemGroup.cpp xpcom/threads/SystemGroup.cpp
-index a95ecc6cdd77..04bf3bd248ef 100644
---- xpcom/threads/SystemGroup.cpp
-+++ xpcom/threads/SystemGroup.cpp
-@@ -16,7 +16,7 @@ class SystemGroupImpl final : public SchedulerGroup
- {
- public:
- SystemGroupImpl();
-- ~SystemGroupImpl() {}
-+ NS_INLINE_DECL_THREADSAFE_REFCOUNTING(SystemGroupImpl)
-
- static void InitStatic();
- static void ShutdownStatic();
-@@ -24,20 +24,12 @@ public:
-
- static bool Initialized() { return !!sSingleton; }
-
-- NS_METHOD_(MozExternalRefCountType) AddRef(void)
-- {
-- return 2;
-- }
-- NS_METHOD_(MozExternalRefCountType) Release(void)
-- {
-- return 1;
-- }
--
- private:
-- static UniquePtr<SystemGroupImpl> sSingleton;
-+ ~SystemGroupImpl() = default;
-+ static StaticRefPtr<SystemGroupImpl> sSingleton;
- };
-
--UniquePtr<SystemGroupImpl> SystemGroupImpl::sSingleton;
-+StaticRefPtr<SystemGroupImpl> SystemGroupImpl::sSingleton;
-
- SystemGroupImpl::SystemGroupImpl()
- {
-@@ -49,7 +41,7 @@ SystemGroupImpl::InitStatic()
- {
- MOZ_ASSERT(!sSingleton);
- MOZ_ASSERT(NS_IsMainThread());
-- sSingleton = MakeUnique<SystemGroupImpl>();
-+ sSingleton = new SystemGroupImpl();
- }
-
- /* static */ void
diff --git a/www/firefox/files/patch-bug1366420 b/www/firefox/files/patch-bug1366420
deleted file mode 100644
index c7b4fabc9b63..000000000000
--- a/www/firefox/files/patch-bug1366420
+++ /dev/null
@@ -1,128 +0,0 @@
-commit dfe9efffb57b
-Author: Marco Bonardo <mbonardo@mozilla.com>
-Date: Wed Oct 4 11:13:19 2017 +0200
-
- Bug 1366420. r=standard8, a=ritu
-
- MozReview-Commit-ID: FOIqr5RdRjz
-
- --HG--
- extra : source : 08312cdfb2304264e6871357fe2e6e7831272d21
----
- toolkit/components/places/BookmarkHTMLUtils.jsm | 2 +-
- .../unit/test_bookmarks_html_escape_entities.js | 81 ++++++++++++++++++++++
- toolkit/components/places/tests/unit/xpcshell.ini | 1 +
- 3 files changed, 83 insertions(+), 1 deletion(-)
-
-diff --git toolkit/components/places/BookmarkHTMLUtils.jsm toolkit/components/places/BookmarkHTMLUtils.jsm
-index 653e29fc5875..f4c1e7495d32 100644
---- toolkit/components/places/BookmarkHTMLUtils.jsm
-+++ toolkit/components/places/BookmarkHTMLUtils.jsm
-@@ -1143,7 +1143,7 @@ BookmarkExporter.prototype = {
- if (aItem.charset)
- this._writeAttribute("LAST_CHARSET", escapeHtmlEntities(aItem.charset));
- if (aItem.tags)
-- this._writeAttribute("TAGS", aItem.tags);
-+ this._writeAttribute("TAGS", escapeHtmlEntities(aItem.tags));
- this._writeLine(">" + escapeHtmlEntities(aItem.title) + "</A>");
- this._writeDescription(aItem, aIndent);
- },
-diff --git toolkit/components/places/tests/unit/test_bookmarks_html_escape_entities.js toolkit/components/places/tests/unit/test_bookmarks_html_escape_entities.js
-new file mode 100644
-index 000000000000..73c5e0e0744d
---- /dev/null
-+++ toolkit/components/places/tests/unit/test_bookmarks_html_escape_entities.js
-@@ -0,0 +1,81 @@
-+/* Any copyright is dedicated to the Public Domain.
-+ * http://creativecommons.org/publicdomain/zero/1.0/ */
-+
-+"use strict";
-+
-+// Checks that html entities are escaped in bookmarks.html files.
-+
-+const DESCRIPTION_ANNO = "bookmarkProperties/description";
-+
-+add_task(async function() {
-+ // Removes bookmarks.html if the file already exists.
-+ let HTMLFile = OS.Path.join(OS.Constants.Path.profileDir, "bookmarks.html");
-+ if ((await OS.File.exists(HTMLFile))) {
-+ await OS.File.remove(HTMLFile);
-+ }
-+
-+ let unescaped = '<unescaped="test">';
-+ // Adds bookmarks and tags to the database.
-+ const url = 'http://www.google.it/"/';
-+ let bm = await PlacesUtils.bookmarks.insert({
-+ parentGuid: PlacesUtils.bookmarks.unfiledGuid,
-+ url,
-+ title: unescaped
-+ });
-+ await PlacesUtils.keywords.insert({ url, keyword: unescaped, postData: unescaped })
-+ let uri = Services.io.newURI(url);
-+ PlacesUtils.tagging.tagURI(uri, [unescaped]);
-+ await PlacesUtils.setCharsetForURI(uri, unescaped);
-+ PlacesUtils.annotations.setItemAnnotation(
-+ await PlacesUtils.promiseItemId(bm.guid),
-+ DESCRIPTION_ANNO, unescaped, 0, PlacesUtils.annotations.EXPIRE_NEVER);
-+
-+ // Exports the bookmarks as a HTML file.
-+ await BookmarkHTMLUtils.exportToFile(HTMLFile);
-+ await PlacesUtils.bookmarks.remove(bm);
-+
-+ // Check there are no unescaped entities in the html file.
-+ let xml = await new Promise((resolve, reject) => {
-+ let xhr = Cc["@mozilla.org/xmlextras/xmlhttprequest;1"]
-+ .createInstance(Ci.nsIXMLHttpRequest);
-+ xhr.onload = () => {
-+ try {
-+ resolve(xhr.responseXML);
-+ } catch (e) {
-+ reject(e);
-+ }
-+ };
-+ xhr.onabort = xhr.onerror = xhr.ontimeout = () => {
-+ reject(new Error("xmlhttprequest failed"));
-+ };
-+ xhr.open("GET", OS.Path.toFileURI(HTMLFile));
-+ xhr.responseType = "document";
-+ xhr.overrideMimeType("text/html");
-+ xhr.send();
-+ });
-+
-+ let checksCount = 6;
-+ for (let current = xml; current;
-+ current = current.firstChild || current.nextSibling || current.parentNode.nextSibling) {
-+ switch (current.nodeType) {
-+ case Ci.nsIDOMNode.ELEMENT_NODE:
-+ for (let {name, value} of current.attributes) {
-+ do_print("Found attribute: " + name);
-+ // Check tags, keyword, postData and charSet.
-+ if (["tags", "last_charset", "shortcuturl", "post_data"].includes(name)) {
-+ Assert.equal(value, unescaped, `Attribute ${name} should be complete`);
-+ checksCount--;
-+ }
-+ }
-+ break;
-+ case Ci.nsIDOMNode.TEXT_NODE:
-+ // Check Title and description.
-+ if (!current.data.startsWith("\n") && !current.data.includes("Bookmarks")) {
-+ Assert.equal(current.data.trim(), unescaped, "Text node should be complete");
-+ checksCount--;
-+ }
-+ break;
-+ }
-+ }
-+ Assert.equal(checksCount, 0, "All the checks ran")
-+});
-diff --git toolkit/components/places/tests/unit/xpcshell.ini toolkit/components/places/tests/unit/xpcshell.ini
-index 6952e4158753..776e7e548f92 100644
---- toolkit/components/places/tests/unit/xpcshell.ini
-+++ toolkit/components/places/tests/unit/xpcshell.ini
-@@ -67,6 +67,7 @@ skip-if = (os == "win" && os_version == "5.1") # Bug 1158887
- [test_bookmarks_json.js]
- [test_bookmarks_html.js]
- [test_bookmarks_html_corrupt.js]
-+[test_bookmarks_html_escape_entities.js]
- [test_bookmarks_html_import_tags.js]
- [test_bookmarks_html_singleframe.js]
- [test_bookmarks_restore_notification.js]
diff --git a/www/firefox/files/patch-bug1369561 b/www/firefox/files/patch-bug1369561
deleted file mode 100644
index d3de0988830a..000000000000
--- a/www/firefox/files/patch-bug1369561
+++ /dev/null
@@ -1,66 +0,0 @@
-commit 4a1737e0c456
-Author: David Keeler <dkeeler@mozilla.com>
-Date: Fri Sep 15 14:47:54 2017 -0700
-
- Bug 1369561 - Address misc. SnprintfLiteral correctness nits. r=jld, r=froydnj, a=ritu
-
- --HG--
- extra : source : f5533b6cd09c35eef381e311940b5bd5231d3553
----
- security/sandbox/linux/SandboxUtil.cpp | 17 ++++++++++-------
- xpcom/base/nsSystemInfo.cpp | 2 +-
- 2 files changed, 11 insertions(+), 8 deletions(-)
-
-diff --git security/sandbox/linux/SandboxUtil.cpp security/sandbox/linux/SandboxUtil.cpp
-index ad6003ecaad5..999329882364 100644
---- security/sandbox/linux/SandboxUtil.cpp
-+++ security/sandbox/linux/SandboxUtil.cpp
-@@ -62,7 +62,6 @@ UnshareUserNamespace()
- uid_t uid = getuid();
- gid_t gid = getgid();
- char buf[80];
-- size_t len;
-
- if (syscall(__NR_unshare, CLONE_NEWUSER) != 0) {
- return false;
-@@ -84,17 +83,21 @@ UnshareUserNamespace()
- // current thread. However, CLONE_NEWUSER can be unshared only in a
- // single-threaded process, so those are equivalent if we reach this
- // point.
-- len = size_t(SprintfLiteral(buf, "%u %u 1\n", uid, uid));
-- MOZ_ASSERT(len < sizeof(buf));
-- if (!WriteStringToFile("/proc/self/uid_map", buf, len)) {
-+ int len = SprintfLiteral(buf, "%u %u 1\n", uid, uid);
-+ if (len >= int(sizeof(buf)) || len < 0) {
-+ return false;
-+ }
-+ if (!WriteStringToFile("/proc/self/uid_map", buf, size_t(len))) {
- MOZ_CRASH("Failed to write /proc/self/uid_map");
- }
-
- Unused << WriteStringToFile("/proc/self/setgroups", "deny", 4);
-
-- len = size_t(SprintfLiteral(buf, "%u %u 1\n", gid, gid));
-- MOZ_ASSERT(len < sizeof(buf));
-- if (!WriteStringToFile("/proc/self/gid_map", buf, len)) {
-+ len = SprintfLiteral(buf, "%u %u 1\n", gid, gid);
-+ if (len >= int(sizeof(buf)) || len < 0) {
-+ return false;
-+ }
-+ if (!WriteStringToFile("/proc/self/gid_map", buf, size_t(len))) {
- MOZ_CRASH("Failed to write /proc/self/gid_map");
- }
- return true;
-diff --git xpcom/base/nsSystemInfo.cpp xpcom/base/nsSystemInfo.cpp
-index e5a7fe97be03..782dc9abf37d 100644
---- xpcom/base/nsSystemInfo.cpp
-+++ xpcom/base/nsSystemInfo.cpp
-@@ -706,7 +706,7 @@ nsSystemInfo::Init()
- }
-
- nsAutoCString secondaryLibrary;
-- if (gtkver_len > 0) {
-+ if (gtkver_len > 0 && gtkver_len < int(sizeof(gtkver))) {
- secondaryLibrary.Append(nsDependentCSubstring(gtkver, gtkver_len));
- }
-
diff --git a/www/firefox/files/patch-bug1370497 b/www/firefox/files/patch-bug1370497
deleted file mode 100644
index e3ea37d54df2..000000000000
--- a/www/firefox/files/patch-bug1370497
+++ /dev/null
@@ -1,100 +0,0 @@
-commit c79086d4c25c
-Author: Jonathan Kew <jkew@mozilla.com>
-Date: Wed Sep 27 11:16:35 2017 +0100
-
- Bug 1370497 - Check ScriptExtensions property of combining marks when available. r=valentin, a=ritu
-
- --HG--
- extra : source : 6bd2d96c0c3d952b205e1bb2f6915cbc820a61a1
- extra : amend_source : b0c6b6fbea0bf77c8d1527e131d3773b4d959ea0
----
- netwerk/dns/nsIDNService.cpp | 45 ++++++++++++++++++++++++++++++++------
- netwerk/test/unit/test_idn_urls.js | 5 +++++
- 2 files changed, 43 insertions(+), 7 deletions(-)
-
-diff --git netwerk/dns/nsIDNService.cpp netwerk/dns/nsIDNService.cpp
-index 4c45a2d52e45..e07910a7e70d 100644
---- netwerk/dns/nsIDNService.cpp
-+++ netwerk/dns/nsIDNService.cpp
-@@ -26,6 +26,7 @@
- const bool kIDNA2008_TransitionalProcessing = false;
-
- #include "ICUUtils.h"
-+#include "unicode/uscript.h"
- #endif
-
- using namespace mozilla::unicode;
-@@ -900,8 +901,8 @@ bool nsIDNService::isLabelSafe(const nsAString &label)
- }
-
- // Check for mixed numbering systems
-- if (GetGeneralCategory(ch) ==
-- HB_UNICODE_GENERAL_CATEGORY_DECIMAL_NUMBER) {
-+ auto genCat = GetGeneralCategory(ch);
-+ if (genCat == HB_UNICODE_GENERAL_CATEGORY_DECIMAL_NUMBER) {
- uint32_t zeroCharacter = ch - GetNumericValue(ch);
- if (savedNumberingSystem == 0) {
- // If we encounter a decimal number, save the zero character from that
-@@ -912,11 +913,41 @@ bool nsIDNService::isLabelSafe(const nsAString &label)
- }
- }
-
-- // Check for consecutive non-spacing marks
-- if (previousChar != 0 &&
-- previousChar == ch &&
-- GetGeneralCategory(ch) == HB_UNICODE_GENERAL_CATEGORY_NON_SPACING_MARK) {
-- return false;
-+ if (genCat == HB_UNICODE_GENERAL_CATEGORY_NON_SPACING_MARK) {
-+ // Check for consecutive non-spacing marks.
-+ if (previousChar != 0 && previousChar == ch) {
-+ return false;
-+ }
-+ // Check for marks whose expected script doesn't match the base script.
-+ if (lastScript != Script::INVALID) {
-+ const size_t kMaxScripts = 32; // more than ample for current values
-+ // of ScriptExtensions property
-+ UScriptCode scripts[kMaxScripts];
-+ UErrorCode errorCode = U_ZERO_ERROR;
-+ int nScripts = uscript_getScriptExtensions(ch, scripts, kMaxScripts,
-+ &errorCode);
-+ MOZ_ASSERT(U_SUCCESS(errorCode), "uscript_getScriptExtensions failed");
-+ if (U_FAILURE(errorCode)) {
-+ return false;
-+ }
-+ // nScripts will always be >= 1, because even for undefined characters
-+ // uscript_getScriptExtensions will return Script::INVALID.
-+ // If the mark just has script=COMMON or INHERITED, we can't check any
-+ // more carefully, but if it has specific scriptExtension codes, then
-+ // assume those are the only valid scripts to use it with.
-+ if (nScripts > 1 ||
-+ (Script(scripts[0]) != Script::COMMON &&
-+ Script(scripts[0]) != Script::INHERITED)) {
-+ while (--nScripts >= 0) {
-+ if (Script(scripts[nScripts]) == lastScript) {
-+ break;
-+ }
-+ }
-+ if (nScripts == -1) {
-+ return false;
-+ }
-+ }
-+ }
- }
-
- // Simplified/Traditional Chinese check temporarily disabled -- bug 857481
-diff --git netwerk/test/unit/test_idn_urls.js netwerk/test/unit/test_idn_urls.js
-index 0d8cf3216293..f39a9650a13b 100644
---- netwerk/test/unit/test_idn_urls.js
-+++ netwerk/test/unit/test_idn_urls.js
-@@ -295,6 +295,11 @@ const testcases = [
- ["䕮䕵䕶䕱.中国123", "xn--google.xn--123-u68dy61b", false, true, true],
- ["xn--accountlogin.䕮䕵䕶䕱", "xn--accountlogin.xn--google", false, true, true],
- ["䕮䕵䕶䕱.xn--accountlogin", "xn--google.xn--accountlogin", false, true, true],
-+
-+ // Arabic diacritic not allowed in Latin text (bug 1370497)
-+ ["goo\u0650gle", "xn--google-yri", false, false, false],
-+ // ...but Arabic diacritics are allowed on Arabic text
-+ ["العَرَبِي", "xn--mgbc0a5a6cxbzabt", false, true, true],
- ];
-
- const profiles = ["ASCII", "high", "moderate"];
diff --git a/www/firefox/files/patch-bug1375146 b/www/firefox/files/patch-bug1375146
deleted file mode 100644
index aa742fd01adb..000000000000
--- a/www/firefox/files/patch-bug1375146
+++ /dev/null
@@ -1,37 +0,0 @@
-commit b481800095d4
-Author: Stone Shih <sshih@mozilla.com>
-Date: Tue Sep 19 15:41:52 2017 +0800
-
- Bug 1375146 - Revise sending drag event. r=smaug, a=ritu
-
- --HG--
- extra : source : d4496b8befbf0ef5ae124a9fbda37ad5b885f9e1
----
- dom/events/EventStateManager.cpp | 7 ++++---
- 1 file changed, 4 insertions(+), 3 deletions(-)
-
-diff --git dom/events/EventStateManager.cpp dom/events/EventStateManager.cpp
-index b94dc0c88e01..1f48884058de 100644
---- dom/events/EventStateManager.cpp
-+++ dom/events/EventStateManager.cpp
-@@ -1292,8 +1292,9 @@ EventStateManager::DispatchCrossProcessEvent(WidgetEvent* aEvent,
- return;
- }
- case eDragEventClass: {
-- if (remote->Manager()->IsContentParent()) {
-- remote->Manager()->AsContentParent()->MaybeInvokeDragSession(remote);
-+ RefPtr<TabParent> tabParent = remote;
-+ if (tabParent->Manager()->IsContentParent()) {
-+ tabParent->Manager()->AsContentParent()->MaybeInvokeDragSession(tabParent);
- }
-
- nsCOMPtr<nsIDragSession> dragSession = nsContentUtils::GetDragSession();
-@@ -1309,7 +1310,7 @@ EventStateManager::DispatchCrossProcessEvent(WidgetEvent* aEvent,
- }
- }
-
-- remote->SendRealDragEvent(*aEvent->AsDragEvent(), action, dropEffect);
-+ tabParent->SendRealDragEvent(*aEvent->AsDragEvent(), action, dropEffect);
- return;
- }
- case ePluginEventClass: {
diff --git a/www/firefox/files/patch-bug1377587 b/www/firefox/files/patch-bug1377587
deleted file mode 100644
index 5e58f504cffd..000000000000
--- a/www/firefox/files/patch-bug1377587
+++ /dev/null
@@ -1,929 +0,0 @@
-commit 2b68b38709b1
-Author: Andrew McCreight <continuation@gmail.com>
-Date: Tue Aug 22 14:24:11 2017 -0700
-
- Bug 1377587, part 1 - Always act like __exposedProps__ is missing. r=krizsa
-
- This patch gently removes support for __exposedProps__ by changing
- ExposedPropertiesOnly::check() to always return false, while still
- failing silently in deny for some kinds of access.
-
- The tests that I changed all involve testing the behavior with
- __exposedProps__. I adjusted them to expect it to fail, or to adjust
- the error message they get when they fail. That seemed better than
- deleting them entirely.
-
- Note that test_bug1065185.html had a bug, so that it never executed
- the first case. I fixed that, and then fixed up the test to work when
- __exposedProps__ is not supported.
-
- This also removes various bits of the test framework that use
- __exposedProps__, but don't actually need to.
-
- MozReview-Commit-ID: 8fvkAmITmXY
-
- --HG--
- extra : rebase_source : ef7e2c55adc12511f17f3865ebb46c343875f0b3
----
- addon-sdk/source/lib/sdk/console/plain-text.js | 10 --
- addon-sdk/source/lib/sdk/test/loader.js | 5 -
- .../addons/e10s-content/lib/test-content-script.js | 6 +-
- addon-sdk/source/test/test-content-script.js | 6 +-
- devtools/server/tests/unit/test_objectgrips-17.js | 4 -
- dom/base/nsDeprecatedOperationList.h | 1 -
- dom/base/test/chrome/cpows_child.js | 12 +-
- dom/locales/en-US/chrome/dom/dom.properties | 2 -
- js/xpconnect/src/XPCJSRuntime.cpp | 1 -
- js/xpconnect/src/xpcprivate.h | 1 -
- js/xpconnect/tests/chrome/test_bug1065185.html | 6 +-
- js/xpconnect/tests/chrome/test_cows.xul | 80 +++------
- js/xpconnect/tests/chrome/test_exposeInDerived.xul | 13 +-
- js/xpconnect/tests/unit/test_bug1082450.js | 20 +--
- js/xpconnect/tests/unit/test_bug780370.js | 7 +-
- js/xpconnect/tests/unit/test_bug813901.js | 2 +-
- js/xpconnect/tests/unit/test_bug853709.js | 4 +-
- js/xpconnect/tests/unit/test_bug854558.js | 2 +-
- js/xpconnect/tests/unit/test_bug930091.js | 2 +-
- js/xpconnect/wrappers/AccessCheck.cpp | 179 ---------------------
- js/xpconnect/wrappers/AccessCheck.h | 11 +-
- js/xpconnect/wrappers/ChromeObjectWrapper.h | 6 +-
- js/xpconnect/wrappers/WrapperFactory.cpp | 4 +-
- js/xpconnect/wrappers/XrayWrapper.cpp | 2 +-
- testing/mochitest/tests/SimpleTest/ChromePowers.js | 9 --
- .../specialpowers/content/MockPermissionPrompt.jsm | 12 --
- .../components/addoncompat/RemoteAddonsParent.jsm | 2 +-
- 27 files changed, 74 insertions(+), 335 deletions(-)
-
-diff --git addon-sdk/source/lib/sdk/console/plain-text.js addon-sdk/source/lib/sdk/console/plain-text.js
-index 0e44cf106d52..07b8eb629e12 100644
---- addon-sdk/source/lib/sdk/console/plain-text.js
-+++ addon-sdk/source/lib/sdk/console/plain-text.js
-@@ -62,16 +62,6 @@ function PlainTextConsole(print, innerID) {
- }
- });
-
-- // We defined the `__exposedProps__` in our console chrome object.
-- //
-- // Meanwhile we're investigating with the platform team if `__exposedProps__`
-- // are needed, or are just a left-over.
--
-- console.__exposedProps__ = Object.keys(ConsoleAPI.prototype).reduce(function(exposed, prop) {
-- exposed[prop] = "r";
-- return exposed;
-- }, {});
--
- Object.freeze(console);
- return console;
- };
-diff --git addon-sdk/source/lib/sdk/test/loader.js addon-sdk/source/lib/sdk/test/loader.js
-index 33ba2ca5a029..b555de63f02a 100644
---- addon-sdk/source/lib/sdk/test/loader.js
-+++ addon-sdk/source/lib/sdk/test/loader.js
-@@ -53,11 +53,6 @@ function HookedPlainTextConsole(hook, print, innerID) {
- this.exception = hook.bind(null, "exception", innerID);
- this.time = hook.bind(null, "time", innerID);
- this.timeEnd = hook.bind(null, "timeEnd", innerID);
--
-- this.__exposedProps__ = {
-- log: "rw", info: "rw", warn: "rw", error: "rw", debug: "rw",
-- exception: "rw", time: "rw", timeEnd: "rw"
-- };
- }
-
- // Creates a custom loader instance whose console module is hooked in order
-diff --git addon-sdk/source/test/addons/e10s-content/lib/test-content-script.js addon-sdk/source/test/addons/e10s-content/lib/test-content-script.js
-index 477895e40481..3dccfec618d3 100644
---- addon-sdk/source/test/addons/e10s-content/lib/test-content-script.js
-+++ addon-sdk/source/test/addons/e10s-content/lib/test-content-script.js
-@@ -444,7 +444,7 @@ exports["test Highlight toString Behavior"] = createProxyTest("", function (help
- let strToString = helper.rawWindow.Object.prototype.toString.call("");
- assert.ok(/\[object String.*\]/.test(strToString), "strings are strings");
-
-- let o = {__exposedProps__:{}};
-+ let o = {};
- let objToString = helper.rawWindow.Object.prototype.toString.call(o);
- assert.ok(/\[object Object.*\]/.test(objToString), "objects are objects");
-
-@@ -622,10 +622,6 @@ exports["test Functions"] = createProxyTest("", function (helper) {
- helper.rawWindow.isEqual = function isEqual(a, b) {
- return a == b;
- };
-- // bug 784116: workaround in order to allow proxy code to cache proxies on
-- // these functions:
-- helper.rawWindow.callFunction.__exposedProps__ = {__proxy: 'rw'};
-- helper.rawWindow.isEqual.__exposedProps__ = {__proxy: 'rw'};
-
- helper.createWorker(
- 'new ' + function ContentScriptScope() {
-diff --git addon-sdk/source/test/test-content-script.js addon-sdk/source/test/test-content-script.js
-index 709fb5a3aa91..a02e66f65eea 100644
---- addon-sdk/source/test/test-content-script.js
-+++ addon-sdk/source/test/test-content-script.js
-@@ -444,7 +444,7 @@ exports["test Highlight toString Behavior"] = createProxyTest("", function (help
- let strToString = helper.rawWindow.Object.prototype.toString.call("");
- assert.ok(/\[object String.*\]/.test(strToString), "strings are strings");
-
-- let o = {__exposedProps__:{}};
-+ let o = {};
- let objToString = helper.rawWindow.Object.prototype.toString.call(o);
- assert.ok(/\[object Object.*\]/.test(objToString), "objects are objects");
-
-@@ -622,10 +622,6 @@ exports["test Functions"] = createProxyTest("", function (helper) {
- helper.rawWindow.isEqual = function isEqual(a, b) {
- return a == b;
- };
-- // bug 784116: workaround in order to allow proxy code to cache proxies on
-- // these functions:
-- helper.rawWindow.callFunction.__exposedProps__ = {__proxy: 'rw'};
-- helper.rawWindow.isEqual.__exposedProps__ = {__proxy: 'rw'};
-
- helper.createWorker(
- 'new ' + function ContentScriptScope() {
-diff --git dom/base/nsDeprecatedOperationList.h dom/base/nsDeprecatedOperationList.h
-index 2523187c63a7..adcf4d9d8202 100644
---- dom/base/nsDeprecatedOperationList.h
-+++ dom/base/nsDeprecatedOperationList.h
-@@ -21,7 +21,6 @@ DEPRECATED_OPERATION(NodeValue)
- DEPRECATED_OPERATION(TextContent)
- DEPRECATED_OPERATION(EnablePrivilege)
- DEPRECATED_OPERATION(DOMExceptionCode)
--DEPRECATED_OPERATION(NoExposedProps)
- DEPRECATED_OPERATION(MutationEvent)
- DEPRECATED_OPERATION(Components)
- DEPRECATED_OPERATION(PrefixedVisibilityAPI)
-diff --git dom/base/test/chrome/cpows_child.js dom/base/test/chrome/cpows_child.js
-index 6d240a7eaa51..fc7e3f2c9d0f 100644
---- dom/base/test/chrome/cpows_child.js
-+++ dom/base/test/chrome/cpows_child.js
-@@ -105,7 +105,13 @@ function parent_test(finish)
-
- addMessageListener("cpows:from_parent", (msg) => {
- let obj = msg.objects.obj;
-- ok(obj.a == 1, "correct value from parent");
-+ if (is_remote) {
-+ ok(obj.a == undefined, "__exposedProps__ should not work");
-+ } else {
-+ // The same process test is not run as content, so the field can
-+ // be accessed even though __exposedProps__ has been removed.
-+ ok(obj.a == 1, "correct value from parent");
-+ }
-
- // Test that a CPOW reference to a function in the chrome process
- // is callable from unprivileged content. Greasemonkey uses this
-@@ -260,11 +266,11 @@ function lifetime_test(finish)
- var obj = {"will_die": {"f": 1}};
- let [result] = sendRpcMessage("cpows:lifetime_test_1", {}, {obj: obj});
- ok(result == 10, "got sync result");
-- ok(obj.wont_die.f == 2, "got reverse CPOW");
-+ ok(obj.wont_die.f == undefined, "got reverse CPOW");
- obj.will_die = null;
- Components.utils.schedulePreciseGC(function() {
- addMessageListener("cpows:lifetime_test_3", (msg) => {
-- ok(obj.wont_die.f == 2, "reverse CPOW still works");
-+ ok(obj.wont_die.f == undefined, "reverse CPOW still works");
- finish();
- });
- sendRpcMessage("cpows:lifetime_test_2");
-diff --git dom/locales/en-US/chrome/dom/dom.properties dom/locales/en-US/chrome/dom/dom.properties
-index 5c94a580287a..ac9dbed58e08 100644
---- dom/locales/en-US/chrome/dom/dom.properties
-+++ dom/locales/en-US/chrome/dom/dom.properties
-@@ -154,8 +154,6 @@ MediaEMENoCapabilitiesDeprecatedWarning=Calling navigator.requestMediaKeySystemA
- MediaEMENoCodecsDeprecatedWarning=Calling navigator.requestMediaKeySystemAccess() (at %S) passing a candidate MediaKeySystemConfiguration containing audioCapabilities or videoCapabilities without a contentType with a “codecs” string is deprecated and will soon become unsupported.
- # LOCALIZATION NOTE: Do not translate "DOMException", "code" and "name"
- DOMExceptionCodeWarning=Use of DOMException’s code attribute is deprecated. Use name instead.
--# LOCALIZATION NOTE: Do not translate "__exposedProps__"
--NoExposedPropsWarning=Exposing chrome JS objects to content without __exposedProps__ is insecure and deprecated. See https://developer.mozilla.org/en/XPConnect_wrappers for more information.
- # LOCALIZATION NOTE: Do not translate "Mutation Event" and "MutationObserver"
- MutationEventWarning=Use of Mutation Events is deprecated. Use MutationObserver instead.
- # LOCALIZATION NOTE: Do not translate "Components"
-diff --git js/xpconnect/src/XPCJSRuntime.cpp js/xpconnect/src/XPCJSRuntime.cpp
-index 455b9f8e963f..ff9aea0a41eb 100644
---- js/xpconnect/src/XPCJSRuntime.cpp
-+++ js/xpconnect/src/XPCJSRuntime.cpp
-@@ -93,7 +93,6 @@ const char* const XPCJSRuntime::mStrings[] = {
- "item", // IDX_ITEM
- "__proto__", // IDX_PROTO
- "__iterator__", // IDX_ITERATOR
-- "__exposedProps__", // IDX_EXPOSEDPROPS
- "eval", // IDX_EVAL
- "controllers", // IDX_CONTROLLERS
- "Controllers", // IDX_CONTROLLERS_CLASS
-diff --git js/xpconnect/src/xpcprivate.h js/xpconnect/src/xpcprivate.h
-index fb7e43c22cd0..5d877f09d301 100644
---- js/xpconnect/src/xpcprivate.h
-+++ js/xpconnect/src/xpcprivate.h
-@@ -460,7 +460,6 @@ public:
- IDX_ITEM ,
- IDX_PROTO ,
- IDX_ITERATOR ,
-- IDX_EXPOSEDPROPS ,
- IDX_EVAL ,
- IDX_CONTROLLERS ,
- IDX_CONTROLLERS_CLASS ,
-diff --git js/xpconnect/tests/chrome/test_bug1065185.html js/xpconnect/tests/chrome/test_bug1065185.html
-index cdd65326f9c8..7ea81fc8aa6f 100644
---- js/xpconnect/tests/chrome/test_bug1065185.html
-+++ js/xpconnect/tests/chrome/test_bug1065185.html
-@@ -25,11 +25,11 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=1065185
-
- var gLoadCount = 0;
- function loaded() {
-- switch(++gLoadCount) {
-+ switch(gLoadCount++) {
- case 0:
-- doMonitor([]);
-+ doMonitor([/access to property "a"/i]);
- window[0].wrappedJSObject.probe = { a: 2, __exposedProps__: { 'a': 'r' } };
-- is(window[0].eval('probe.a'), 2, "Accessed exposed prop");
-+ is(window[0].eval('probe.a'), undefined, "Accessed exposed prop");
- endMonitor();
- break;
- case 1:
-diff --git js/xpconnect/tests/chrome/test_cows.xul js/xpconnect/tests/chrome/test_cows.xul
-index 75c5250dd150..adfdd686540b 100644
---- js/xpconnect/tests/chrome/test_cows.xul
-+++ js/xpconnect/tests/chrome/test_cows.xul
-@@ -49,13 +49,6 @@ sandbox.getCOW = getCOW;
- const TEST_API = ['is', 'isnot', 'ok', 'todo_is', 'todo_isnot', 'todo'];
- TEST_API.forEach(function(name) { sandbox[name] = window[name]; });
-
--sandbox.alienObject = {
-- __exposedProps__: {funProp: 'r'},
-- funProp: function foo(x) {
-- return x + 1;
-- }
--};
--
- sandbox.chromeGet = function (obj, prop) { return obj[prop]; };
-
- function COWTests() {
-@@ -74,17 +67,6 @@ function COWTests() {
- // functions like assertIsWritable(myObj, 'someproperty') might
- // be useful.
-
-- function isProp(obj, propName, value, desc) {
-- try {
-- is(obj[propName], value, "getting " + propName + " on " + desc);
-- ok(propName in obj,
-- propName + " on " + desc + " should exist");
-- ok(Object.hasOwnProperty.call(obj, propName),
-- propName + " on " + desc + " should exist");
-- } catch (e) {
-- ok(false, "getting " + propName + " on " + desc + " threw " + e);
-- }
-- }
- function isPropHidden(obj, propName, desc) {
- try {
- is(obj[propName], undefined,
-@@ -103,7 +85,7 @@ function COWTests() {
- var empty = {};
- var nonempty = {foo: 42, bar: 33};
- is(getCOW(empty).foo, undefined,
-- "shouldn't throw when accessing exposed properties that doesn't exist");
-+ "shouldn't throw when accessing exposed properties that don't exist");
-
- PROPS_TO_TEST.forEach(function(name) {
- isPropHidden(getCOW(nonempty), name, "object without exposedProps");
-@@ -135,18 +117,12 @@ function COWTests() {
- var strict = { __exposedProps__: { foo: "r" }, foo: "foo property" };
- var strictCOWr = getCOW(strict);
- PROPS_TO_TEST.forEach(function(name) {
-- if (name == "foo") {
-- isProp(strictCOWr, name, "foo property",
-- "object with exposed 'foo'");
-- }
-- else {
-- isPropHidden(strictCOW, name, "object with exposed 'foo'");
-- }
-+ isPropHidden(strictCOW, name, "object with exposed 'foo'");
- });
-- is(getNames(strictCOWr).length, 1,
-- "object with exposedProps only enumerate exposed props");
-- is(getNames(strictCOWr)[0], "foo",
-- "object with exposedProps only enumerate exposed props");
-+ is(getNames(strictCOWr).length, 0,
-+ "exposed props does not enumerate anything");
-+ is(getNames(strictCOWr)[0], undefined,
-+ "exposed props does not enumerate anything");
-
- // Test writable property
- var writable = getCOW({ __exposedProps__: {foo: 'w'}});
-@@ -154,25 +130,18 @@ function COWTests() {
- ok(!("foo" in writable),
- "non-existing write-only property shouldn't exist");
- writable.foo = 5;
-- is(chromeGet(writable, "foo"), 5, "writing to a write-only exposed prop works");
-- todo("foo" in writable,
-- "existing write-only property should exist");
-- } catch (e) {
-- ok(false, "writing to a write-only exposed prop shouldn't throw " + e);
-- }
-- try {
-- writable.foo;
-- todo(false, "reading from a write-only exposed prop should throw");
-+ ok(false, "writing to a write-only exposed prop should throw");
- } catch (e) {
-- todo(/Permission denied/.test(e),
-- "reading from a write-only exposed prop should throw");
-+ ok(/Permission denied/.test(e),
-+ "writing to a write-only exposed prop should throw the right error");
- }
-+ is(writable.foo, undefined,
-+ "reading from a write-only exposed prop should return undefined");
- try {
- delete writable.foo;
-- is(chromeGet(writable, "foo"), undefined,
-- "deleting a write-only exposed prop works");
-+ ok(false, "deleting a write-only exposed prop should throw");
- } catch (e) {
-- ok(false, "deleting a write-only exposed prop shouldn't throw " + e);
-+ ok(true, "deleting a write-only exposed prop should throw " + e);
- }
-
- // Test readable property
-@@ -180,8 +149,8 @@ function COWTests() {
- foo: 5,
- bar: 6 };
- try {
-- isProp(getCOW(readable), "foo", 5,
-- "reading from a readable exposed prop works");
-+ isPropHidden(getCOW(readable), "foo", undefined,
-+ "reading from a readable exposed prop shouldn't work");
- } catch (e) {
- ok(false, "reading from a readable exposed prop shouldn't throw " + e);
- }
-@@ -202,8 +171,7 @@ function COWTests() {
-
- try {
- var props = getNames(getCOW(readable));
-- is(props.length, 1, "COW w/ one exposed prop should enumerate once");
-- is(props[0], 'foo', "COW w/ one exposed prop should enumerate it");
-+ is(props.length, 0, "COW w/ one exposed prop should not enumerate");
- } catch (e) {
- ok(false, "COW w/ a readable prop should not raise exc " +
- "on enumeration: " + e);
-@@ -215,21 +183,17 @@ function COWTests() {
- ok(!("foo" in readwrite),
- "non-existing readwrite property shouldn't exist");
- readwrite.foo = 5;
-- is(readwrite.foo, 5, "writing to a readwrite exposed prop looks like it worked");
-- is(chromeGet(readwrite, "foo"), 5, "writing to a readwrite exposed prop works");
-- ok("foo" in readwrite,
-- "existing readwrite property should exist");
-+ ok(false, "writing to a readwrite exposed prop should throw");
- } catch (e) {
-- ok(false, "writing to a readwrite exposed prop shouldn't throw " + e);
-+ ok(/Permission denied/.test(e),
-+ "writing to a readwrite exposed prop should throw the right error");
- }
- try {
- delete readwrite.foo;
-- is(readwrite.foo, undefined, "deleting readwrite prop looks like it worked");
-- ok(!("foo" in readwrite), "deleting readwrite prop looks like it really worked");
-- is(chromeGet(readwrite, "foo"), undefined,
-- "deleting a readwrite exposed prop works");
-+ ok(false, "deleting a readwrite prop should throw");
- } catch (e) {
-- ok(false, "deleting a readwrite exposed prop shouldn't throw " + e);
-+ ok(/Permission denied/.test(e),
-+ "deleting a readwrite exposed prop should throw the right error");
- }
-
- // Readables and functions
-diff --git js/xpconnect/tests/chrome/test_exposeInDerived.xul js/xpconnect/tests/chrome/test_exposeInDerived.xul
-index 2ed3bb91e7fd..7e6c24e56db1 100644
---- js/xpconnect/tests/chrome/test_exposeInDerived.xul
-+++ js/xpconnect/tests/chrome/test_exposeInDerived.xul
-@@ -17,7 +17,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=804630
- <!-- test code goes here -->
- <script type="application/javascript">
- <![CDATA[
-- /** Test to make sure that COWed objects can expose properties from their prototypes. **/
-+ /** Test to make sure that COWed objects can't expose properties from their prototypes. **/
- const Cu = Components.utils;
-
- // Set up the sandbox.
-@@ -25,7 +25,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=804630
- sb.ok = ok;
- sb.is = is;
-
-- // Make a chrome object that exposes objects off its prototype.
-+ // Make a chrome object that tries to expose objects off its prototype.
- sb.proto = { read: 42, readWrite: 32, __exposedProps__: {} };
- sb.obj = { __exposedProps__: { read: 'r', readWrite: 'rw' } };
- sb.obj.__proto__ = sb.proto;
-@@ -36,10 +36,11 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=804630
- 'try { proto.readWrite = 12; wrote = true; } catch(e) {} ' +
- ' ok(!wrote, "Should not write proto property");', sb);
-
-- // Make sure we can access the exposed properties via the derived object.
-- Cu.evalInSandbox('is(obj.read, 42, "obj.read accessible");', sb);
-- Cu.evalInSandbox('is(obj.readWrite, 32, "obj.readWrite is readable");', sb);
-- Cu.evalInSandbox('obj.readWrite = 8; is(obj.readWrite, 8, "obj.readWrite is writable");', sb);
-+ // Make sure we can't access the exposed properties via the derived object.
-+ Cu.evalInSandbox('is(obj.read, undefined, "obj.read inaccessible");', sb);
-+ Cu.evalInSandbox('is(obj.readWrite, undefined, "obj.readWrite is not readable");', sb);
-+ Cu.evalInSandbox('try { obj.readWrite = 8; ok(false, "obj.readWrite is not writable"); } catch (e) {};',
-+ sb);
-
- ]]>
- </script>
-diff --git js/xpconnect/tests/unit/test_bug1082450.js js/xpconnect/tests/unit/test_bug1082450.js
-index 07f45f06beef..5880fcbcd4e6 100644
---- js/xpconnect/tests/unit/test_bug1082450.js
-+++ js/xpconnect/tests/unit/test_bug1082450.js
-@@ -5,9 +5,9 @@ function run_test() {
- function checkThrows(str, rgxp) {
- try {
- sb.eval(str);
-- do_check_true(false);
-+ do_check_true(false, "eval should have thrown");
- } catch (e) {
-- do_check_true(rgxp.test(e));
-+ do_check_true(rgxp.test(e), "error message should match");
- }
- }
-
-@@ -29,12 +29,12 @@ function run_test() {
- chromeCallableValueProp: 'r' }
- };
-
-- do_check_eq(sb.eval('exposed.simpleValueProp'), 42);
-- do_check_eq(sb.eval('exposed.objectValueProp.val'), 42);
-- checkThrows('exposed.getterProp;', /privileged accessor/i);
-- checkThrows('exposed.setterProp = 42;', /privileged accessor/i);
-- checkThrows('exposed.getterSetterProp;', /privileged accessor/i);
-- checkThrows('exposed.getterSetterProp = 42;', /privileged accessor/i);
-- do_check_eq(sb.eval('exposed.contentCallableValueProp()'), 42);
-- checkThrows('exposed.chromeCallableValueProp();', /privileged or cross-origin callable/i);
-+ do_check_eq(sb.eval('exposed.simpleValueProp'), undefined);
-+ do_check_eq(sb.eval('exposed.objectValueProp'), undefined);
-+ do_check_eq(sb.eval('exposed.getterProp;'), undefined);
-+ do_check_eq(sb.eval('exposed.getterSetterProp;'), undefined);
-+ checkThrows('exposed.setterProp = 42;', /Permission denied/i);
-+ checkThrows('exposed.getterSetterProp = 42;', /Permission denied/i);
-+ do_check_eq(sb.eval('exposed.contentCallableValueProp'), undefined);
-+ checkThrows('exposed.chromeCallableValueProp();', /is not a function/i);
- }
-diff --git js/xpconnect/tests/unit/test_bug780370.js js/xpconnect/tests/unit/test_bug780370.js
-index 40d6f9748015..7ae757f0cd01 100644
---- js/xpconnect/tests/unit/test_bug780370.js
-+++ js/xpconnect/tests/unit/test_bug780370.js
-@@ -14,10 +14,5 @@ function run_test()
- var sb = Cu.Sandbox("http://www.example.com");
- sb.obj = { foo: 42, __exposedProps__: { hasOwnProperty: 'r' } };
- do_check_eq(Cu.evalInSandbox('typeof obj.foo', sb), 'undefined', "COW works as expected");
-- try {
-- Cu.evalInSandbox('obj.hasOwnProperty', sb);
-- do_check_true(false);
-- } catch (e) {
-- do_check_true(/privileged or cross-origin callable/i.test(e));
-- }
-+ do_check_eq(Cu.evalInSandbox('obj.hasOwnProperty', sb), undefined);
- }
-diff --git js/xpconnect/tests/unit/test_bug813901.js js/xpconnect/tests/unit/test_bug813901.js
-index 42f981581b51..2efc6539e879 100644
---- js/xpconnect/tests/unit/test_bug813901.js
-+++ js/xpconnect/tests/unit/test_bug813901.js
-@@ -21,5 +21,5 @@ function run_test() {
- checkThrows('obj.foo = 3;', sb, /denied/);
- Cu.evalInSandbox("var p = {__exposedProps__: {foo: 'rw'}};", sb);
- sb.obj.__proto__ = sb.p;
-- checkThrows('obj.foo = 4;', sb, /__exposedProps__/);
-+ checkThrows('obj.foo = 4;', sb, /denied/);
- }
-diff --git js/xpconnect/tests/unit/test_bug853709.js js/xpconnect/tests/unit/test_bug853709.js
-index c7e51757dc63..1667d2241f93 100644
---- js/xpconnect/tests/unit/test_bug853709.js
-+++ js/xpconnect/tests/unit/test_bug853709.js
-@@ -8,7 +8,7 @@ function setupChromeSandbox() {
- function checkDefineThrows(sb, obj, prop, desc) {
- var result = Cu.evalInSandbox('(function() { try { Object.defineProperty(' + obj + ', "' + prop + '", ' + desc.toSource() + '); return "nothrow"; } catch (e) { return e.toString(); }})();', sb);
- do_check_neq(result, 'nothrow');
-- do_check_true(!!/denied/.exec(result));
-+ do_check_true(!!/denied|prohibited/.exec(result));
- do_check_true(result.indexOf(prop) != -1); // Make sure the prop name is in the error message.
- }
-
-@@ -19,7 +19,7 @@ function run_test() {
- contentSB.chromeObj = chromeSB.chromeObj;
- contentSB.chromeArr = chromeSB.chromeArr;
-
-- do_check_eq(Cu.evalInSandbox('chromeObj.a', contentSB), 2);
-+ do_check_eq(Cu.evalInSandbox('chromeObj.a', contentSB), undefined);
- try {
- Cu.evalInSandbox('chromeArr[1]', contentSB);
- do_check_true(false);
-diff --git js/xpconnect/tests/unit/test_bug854558.js js/xpconnect/tests/unit/test_bug854558.js
-index d60d23a5baf8..574194dc3f52 100644
---- js/xpconnect/tests/unit/test_bug854558.js
-+++ js/xpconnect/tests/unit/test_bug854558.js
-@@ -7,5 +7,5 @@ function run_test() {
- contentSB.foo = chromeSB.foo;
- do_check_eq(Cu.evalInSandbox('foo.a', contentSB), undefined, "Default deny with no __exposedProps__");
- Cu.evalInSandbox('this.foo.__exposedProps__ = {a: "r"}', chromeSB);
-- do_check_eq(Cu.evalInSandbox('foo.a', contentSB), 2, "works with __exposedProps__");
-+ do_check_eq(Cu.evalInSandbox('foo.a', contentSB), undefined, "Still not allowed with __exposedProps__");
- }
-diff --git js/xpconnect/tests/unit/test_bug930091.js js/xpconnect/tests/unit/test_bug930091.js
-index aa11d5db2640..ecb2a60aed11 100644
---- js/xpconnect/tests/unit/test_bug930091.js
-+++ js/xpconnect/tests/unit/test_bug930091.js
-@@ -5,7 +5,7 @@ function checkThrows(fn) {
- fn();
- ok(false, "Should have thrown");
- } catch (e) {
-- do_check_true(/denied|insecure/.test(e));
-+ do_check_true(/denied|insecure|prohibited/.test(e));
- }
- }
-
-diff --git js/xpconnect/wrappers/AccessCheck.cpp js/xpconnect/wrappers/AccessCheck.cpp
-index 07599ce7906a..b730310731e2 100644
---- js/xpconnect/wrappers/AccessCheck.cpp
-+++ js/xpconnect/wrappers/AccessCheck.cpp
-@@ -252,20 +252,6 @@ AccessCheck::checkPassToPrivilegedCode(JSContext* cx, HandleObject wrapper, Hand
- return true;
- }
-
-- // COWs are fine to pass to chrome if and only if they have __exposedProps__,
-- // since presumably content should never have a reason to pass an opaque
-- // object back to chrome.
-- if (AccessCheck::isChrome(js::UncheckedUnwrap(wrapper)) && WrapperFactory::IsCOW(obj)) {
-- RootedObject target(cx, js::UncheckedUnwrap(obj));
-- JSAutoCompartment ac(cx, target);
-- RootedId id(cx, GetJSIDByIndex(cx, XPCJSContext::IDX_EXPOSEDPROPS));
-- bool found = false;
-- if (!JS_HasPropertyById(cx, target, id, &found))
-- return false;
-- if (found)
-- return true;
-- }
--
- // Same-origin wrappers are fine.
- if (AccessCheck::wrapperSubsumes(obj))
- return true;
-@@ -323,171 +309,6 @@ AccessCheck::reportCrossOriginDenial(JSContext* cx, JS::HandleId id,
- MOZ_ALWAYS_TRUE(rv.MaybeSetPendingException(cx));
- }
-
--enum Access { READ = (1<<0), WRITE = (1<<1), NO_ACCESS = 0 };
--
--static void
--EnterAndThrowASCII(JSContext* cx, JSObject* wrapper, const char* msg)
--{
-- JSAutoCompartment ac(cx, wrapper);
-- JS_ReportErrorASCII(cx, "%s", msg);
--}
--
--bool
--ExposedPropertiesOnly::check(JSContext* cx, HandleObject wrapper, HandleId id, Wrapper::Action act)
--{
-- RootedObject wrappedObject(cx, Wrapper::wrappedObject(wrapper));
--
-- if (act == Wrapper::CALL)
-- return false;
--
-- // For the case of getting a property descriptor, we allow if either GET or SET
-- // is allowed, and rely on FilteringWrapper to filter out any disallowed accessors.
-- if (act == Wrapper::GET_PROPERTY_DESCRIPTOR) {
-- return check(cx, wrapper, id, Wrapper::GET) ||
-- check(cx, wrapper, id, Wrapper::SET);
-- }
--
-- RootedId exposedPropsId(cx, GetJSIDByIndex(cx, XPCJSContext::IDX_EXPOSEDPROPS));
--
-- // We need to enter the wrappee's compartment to look at __exposedProps__,
-- // but we want to be in the wrapper's compartment if we call Deny().
-- //
-- // Unfortunately, |cx| can be in either compartment when we call ::check. :-(
-- JSAutoCompartment ac(cx, wrappedObject);
--
-- bool found = false;
-- if (!JS_HasPropertyById(cx, wrappedObject, exposedPropsId, &found))
-- return false;
--
-- // If no __exposedProps__ existed, deny access.
-- if (!found) {
-- // Previously we automatically granted access to indexed properties and
-- // .length for Array COWs. We're not doing that anymore, so make sure to
-- // let people know what's going on.
-- bool isArray;
-- if (!JS_IsArrayObject(cx, wrappedObject, &isArray))
-- return false;
-- if (!isArray)
-- isArray = JS_IsTypedArrayObject(wrappedObject);
-- bool isIndexedAccessOnArray = isArray && JSID_IS_INT(id) && JSID_TO_INT(id) >= 0;
-- bool isLengthAccessOnArray = isArray && JSID_IS_STRING(id) &&
-- JS_FlatStringEqualsAscii(JSID_TO_FLAT_STRING(id), "length");
-- if (isIndexedAccessOnArray || isLengthAccessOnArray) {
-- JSAutoCompartment ac2(cx, wrapper);
-- ReportWrapperDenial(cx, id, WrapperDenialForCOW,
-- "Access to elements and length of privileged Array not permitted");
-- }
--
-- return false;
-- }
--
-- if (id == JSID_VOID)
-- return true;
--
-- Rooted<PropertyDescriptor> desc(cx);
-- if (!JS_GetPropertyDescriptorById(cx, wrappedObject, exposedPropsId, &desc))
-- return false;
--
-- if (!desc.object())
-- return false;
--
-- if (desc.hasGetterOrSetter()) {
-- EnterAndThrowASCII(cx, wrapper, "__exposedProps__ must be a value property");
-- return false;
-- }
--
-- RootedValue exposedProps(cx, desc.value());
-- if (exposedProps.isNullOrUndefined())
-- return false;
--
-- if (!exposedProps.isObject()) {
-- EnterAndThrowASCII(cx, wrapper, "__exposedProps__ must be undefined, null, or an Object");
-- return false;
-- }
--
-- RootedObject hallpass(cx, &exposedProps.toObject());
--
-- if (!AccessCheck::subsumes(js::UncheckedUnwrap(hallpass), wrappedObject)) {
-- EnterAndThrowASCII(cx, wrapper, "Invalid __exposedProps__");
-- return false;
-- }
--
-- Access access = NO_ACCESS;
--
-- if (!JS_GetPropertyDescriptorById(cx, hallpass, id, &desc)) {
-- return false; // Error
-- }
-- if (!desc.object() || !desc.enumerable())
-- return false;
--
-- if (!desc.value().isString()) {
-- EnterAndThrowASCII(cx, wrapper, "property must be a string");
-- return false;
-- }
--
-- JSFlatString* flat = JS_FlattenString(cx, desc.value().toString());
-- if (!flat)
-- return false;
--
-- size_t length = JS_GetStringLength(JS_FORGET_STRING_FLATNESS(flat));
--
-- for (size_t i = 0; i < length; ++i) {
-- char16_t ch = JS_GetFlatStringCharAt(flat, i);
-- switch (ch) {
-- case 'r':
-- if (access & READ) {
-- EnterAndThrowASCII(cx, wrapper, "duplicate 'readable' property flag");
-- return false;
-- }
-- access = Access(access | READ);
-- break;
--
-- case 'w':
-- if (access & WRITE) {
-- EnterAndThrowASCII(cx, wrapper, "duplicate 'writable' property flag");
-- return false;
-- }
-- access = Access(access | WRITE);
-- break;
--
-- default:
-- EnterAndThrowASCII(cx, wrapper, "properties can only be readable or read and writable");
-- return false;
-- }
-- }
--
-- if (access == NO_ACCESS) {
-- EnterAndThrowASCII(cx, wrapper, "specified properties must have a permission bit set");
-- return false;
-- }
--
-- if ((act == Wrapper::SET && !(access & WRITE)) ||
-- (act != Wrapper::SET && !(access & READ))) {
-- return false;
-- }
--
-- // Inspect the property on the underlying object to check for red flags.
-- if (!JS_GetPropertyDescriptorById(cx, wrappedObject, id, &desc))
-- return false;
--
-- // Reject accessor properties.
-- if (desc.hasGetterOrSetter()) {
-- EnterAndThrowASCII(cx, wrapper, "Exposing privileged accessor properties is prohibited");
-- return false;
-- }
--
-- // Reject privileged or cross-origin callables.
-- if (desc.value().isObject()) {
-- RootedObject maybeCallable(cx, js::UncheckedUnwrap(&desc.value().toObject()));
-- if (JS::IsCallable(maybeCallable) && !AccessCheck::subsumes(wrapper, maybeCallable)) {
-- EnterAndThrowASCII(cx, wrapper, "Exposing privileged or cross-origin callable is prohibited");
-- return false;
-- }
-- }
--
-- return true;
--}
--
- bool
- ExposedPropertiesOnly::deny(JSContext* cx, js::Wrapper::Action act, HandleId id,
- bool mayThrow)
-diff --git js/xpconnect/wrappers/AccessCheck.h js/xpconnect/wrappers/AccessCheck.h
-index 678dce3e0b81..c4873760ab7a 100644
---- js/xpconnect/wrappers/AccessCheck.h
-+++ js/xpconnect/wrappers/AccessCheck.h
-@@ -104,10 +104,15 @@ struct CrossOriginAccessiblePropertiesOnly : public Policy {
- }
- };
-
--// This policy only permits access to properties if they appear in the
--// objects exposed properties list.
-+// This class used to support permitting access to properties if they
-+// appeared in an access list on the object, but now it acts like an
-+// Opaque wrapper, with the exception that it fails silently for GET,
-+// ENUMERATE, and GET_PROPERTY_DESCRIPTOR. This is done for backwards
-+// compatibility. See bug 1397513.
- struct ExposedPropertiesOnly : public Policy {
-- static bool check(JSContext* cx, JS::HandleObject wrapper, JS::HandleId id, js::Wrapper::Action act);
-+ static bool check(JSContext* cx, JS::HandleObject wrapper, JS::HandleId id, js::Wrapper::Action act) {
-+ return false;
-+ }
-
- static bool deny(JSContext* cx, js::Wrapper::Action act, JS::HandleId id,
- bool mayThrow);
-diff --git js/xpconnect/wrappers/ChromeObjectWrapper.h js/xpconnect/wrappers/ChromeObjectWrapper.h
-index 8b273e470814..c17feed10b9a 100644
---- js/xpconnect/wrappers/ChromeObjectWrapper.h
-+++ js/xpconnect/wrappers/ChromeObjectWrapper.h
-@@ -16,9 +16,9 @@ namespace xpc {
- struct ExposedPropertiesOnly;
-
- // When a vanilla chrome JS object is exposed to content, we use a wrapper that
--// supports __exposedProps__ for legacy reasons. For extra security, we override
--// the traps that allow content to pass an object to chrome, and perform extra
--// security checks on them.
-+// fails silently on GET, ENUMERATE, and GET_PROPERTY_DESCRIPTOR for legacy
-+// reasons. For extra security, we override the traps that allow content to pass
-+// an object to chrome, and perform extra security checks on them.
- #define ChromeObjectWrapperBase \
- FilteringWrapper<js::CrossCompartmentSecurityWrapper, ExposedPropertiesOnly>
-
-diff --git js/xpconnect/wrappers/WrapperFactory.cpp js/xpconnect/wrappers/WrapperFactory.cpp
-index 6296f69fbea4..760d2c9afda8 100644
---- js/xpconnect/wrappers/WrapperFactory.cpp
-+++ js/xpconnect/wrappers/WrapperFactory.cpp
-@@ -514,8 +514,8 @@ WrapperFactory::Rewrap(JSContext* cx, HandleObject existing, HandleObject obj)
- wrapper = &FilteringWrapper<CrossCompartmentSecurityWrapper, OpaqueWithCall>::singleton;
- }
-
-- // For Vanilla JSObjects exposed from chrome to content, we use a wrapper
-- // that supports __exposedProps__. We'd like to get rid of these eventually,
-+ // For vanilla JSObjects exposed from chrome to content, we use a wrapper
-+ // that fails silently in a few cases. We'd like to get rid of this eventually,
- // but in their current form they don't cause much trouble.
- else if (IdentifyStandardInstance(obj) == JSProto_Object) {
- wrapper = &ChromeObjectWrapper::singleton;
-diff --git js/xpconnect/wrappers/XrayWrapper.cpp js/xpconnect/wrappers/XrayWrapper.cpp
-index 44dd7cb47146..28e29ea13d93 100644
---- js/xpconnect/wrappers/XrayWrapper.cpp
-+++ js/xpconnect/wrappers/XrayWrapper.cpp
-@@ -291,7 +291,7 @@ ReportWrapperDenial(JSContext* cx, HandleId id, WrapperDenialType type, const ch
- MOZ_ASSERT(type == WrapperDenialForCOW);
- errorMessage.emplace("Security wrapper denied access to property %s on privileged "
- "Javascript object. Support for exposing privileged objects "
-- "to untrusted content via __exposedProps__ is being gradually "
-+ "to untrusted content via __exposedProps__ has been "
- "removed - use WebIDL bindings or Components.utils.cloneInto "
- "instead. Note that only the first denied property access from a "
- "given global object will be reported.",
-diff --git testing/mochitest/tests/SimpleTest/ChromePowers.js testing/mochitest/tests/SimpleTest/ChromePowers.js
-index 97de578157c0..7fbf66e2fd00 100644
---- testing/mochitest/tests/SimpleTest/ChromePowers.js
-+++ testing/mochitest/tests/SimpleTest/ChromePowers.js
-@@ -104,15 +104,6 @@ ChromePowers.prototype.executeAfterFlushingMessageQueue = function(aCallback) {
- aCallback();
- };
-
--// Expose everything but internal APIs (starting with underscores) to
--// web content. We cannot use Object.keys to view SpecialPowers.prototype since
--// we are using the functions from SpecialPowersAPI.prototype
--ChromePowers.prototype.__exposedProps__ = {};
--for (var i in ChromePowers.prototype) {
-- if (i.charAt(0) != "_")
-- ChromePowers.prototype.__exposedProps__[i] = "r";
--}
--
- if ((window.parent !== null) &&
- (window.parent !== undefined) &&
- (window.parent.wrappedJSObject.SpecialPowers) &&
-diff --git testing/specialpowers/content/MockPermissionPrompt.jsm testing/specialpowers/content/MockPermissionPrompt.jsm
-index 71d0f5d2768a..1d86cc00e360 100644
---- testing/specialpowers/content/MockPermissionPrompt.jsm
-+++ testing/specialpowers/content/MockPermissionPrompt.jsm
-@@ -83,15 +83,3 @@ MockPermissionPromptInstance.prototype = {
- request.allow();
- }
- };
--
--// Expose everything to content. We call reset() here so that all of the relevant
--// lazy expandos get added.
--MockPermissionPrompt.reset();
--function exposeAll(obj) {
-- var props = {};
-- for (var prop in obj)
-- props[prop] = "rw";
-- obj.__exposedProps__ = props;
--}
--exposeAll(MockPermissionPrompt);
--exposeAll(MockPermissionPromptInstance.prototype);
-diff --git toolkit/components/addoncompat/RemoteAddonsParent.jsm toolkit/components/addoncompat/RemoteAddonsParent.jsm
-index 1adbc0397729..d640c47d31f8 100644
---- toolkit/components/addoncompat/RemoteAddonsParent.jsm
-+++ toolkit/components/addoncompat/RemoteAddonsParent.jsm
-@@ -735,7 +735,7 @@ var SandboxParent = {
- if (rest.length) {
- // Do a shallow copy of the options object into the child
- // process. This way we don't have to access it through a Chrome
-- // object wrapper, which would require __exposedProps__.
-+ // object wrapper, which would not let us access any properties.
- //
- // The only object property here is sandboxPrototype. We assume
- // it's a child process object (since that's what Greasemonkey
-commit f89c72edb79e
-Author: Andrew McCreight <continuation@gmail.com>
-Date: Thu Sep 7 11:17:16 2017 -0700
-
- Bug 1377587, part 2 - Rename ExposedPropertiesOnly to OpaqueWithSilentFailing. r=krizsa
-
- This class doesn't have anything to do with __exposedProps__ any more,
- so give it a more descriptive name. We'd still like to remove it
- entirely eventually.
-
- MozReview-Commit-ID: 87KCpG6f8rI
-
- --HG--
- extra : rebase_source : 98a51a6af0fc8446dbcd8efa083d6c79286279d3
----
- js/xpconnect/wrappers/AccessCheck.cpp | 4 ++--
- js/xpconnect/wrappers/AccessCheck.h | 2 +-
- js/xpconnect/wrappers/ChromeObjectWrapper.h | 4 ++--
- 3 files changed, 5 insertions(+), 5 deletions(-)
-
-diff --git js/xpconnect/wrappers/AccessCheck.cpp js/xpconnect/wrappers/AccessCheck.cpp
-index b730310731e2..620f1f678f51 100644
---- js/xpconnect/wrappers/AccessCheck.cpp
-+++ js/xpconnect/wrappers/AccessCheck.cpp
-@@ -310,8 +310,8 @@ AccessCheck::reportCrossOriginDenial(JSContext* cx, JS::HandleId id,
- }
-
- bool
--ExposedPropertiesOnly::deny(JSContext* cx, js::Wrapper::Action act, HandleId id,
-- bool mayThrow)
-+OpaqueWithSilentFailing::deny(JSContext* cx, js::Wrapper::Action act, HandleId id,
-+ bool mayThrow)
- {
- // Fail silently for GET, ENUMERATE, and GET_PROPERTY_DESCRIPTOR.
- if (act == js::Wrapper::GET || act == js::Wrapper::ENUMERATE ||
-diff --git js/xpconnect/wrappers/AccessCheck.h js/xpconnect/wrappers/AccessCheck.h
-index c4873760ab7a..6783258f8d94 100644
---- js/xpconnect/wrappers/AccessCheck.h
-+++ js/xpconnect/wrappers/AccessCheck.h
-@@ -109,7 +109,7 @@ struct CrossOriginAccessiblePropertiesOnly : public Policy {
- // Opaque wrapper, with the exception that it fails silently for GET,
- // ENUMERATE, and GET_PROPERTY_DESCRIPTOR. This is done for backwards
- // compatibility. See bug 1397513.
--struct ExposedPropertiesOnly : public Policy {
-+struct OpaqueWithSilentFailing : public Policy {
- static bool check(JSContext* cx, JS::HandleObject wrapper, JS::HandleId id, js::Wrapper::Action act) {
- return false;
- }
-diff --git js/xpconnect/wrappers/ChromeObjectWrapper.h js/xpconnect/wrappers/ChromeObjectWrapper.h
-index c17feed10b9a..da4870237501 100644
---- js/xpconnect/wrappers/ChromeObjectWrapper.h
-+++ js/xpconnect/wrappers/ChromeObjectWrapper.h
-@@ -13,14 +13,14 @@
-
- namespace xpc {
-
--struct ExposedPropertiesOnly;
-+struct OpaqueWithSilentFailing;
-
- // When a vanilla chrome JS object is exposed to content, we use a wrapper that
- // fails silently on GET, ENUMERATE, and GET_PROPERTY_DESCRIPTOR for legacy
- // reasons. For extra security, we override the traps that allow content to pass
- // an object to chrome, and perform extra security checks on them.
- #define ChromeObjectWrapperBase \
-- FilteringWrapper<js::CrossCompartmentSecurityWrapper, ExposedPropertiesOnly>
-+ FilteringWrapper<js::CrossCompartmentSecurityWrapper, OpaqueWithSilentFailing>
-
- class ChromeObjectWrapper : public ChromeObjectWrapperBase
- {
-
diff --git a/www/firefox/files/patch-bug1381761 b/www/firefox/files/patch-bug1381761
deleted file mode 100644
index 416bd4ac8c26..000000000000
--- a/www/firefox/files/patch-bug1381761
+++ /dev/null
@@ -1,362 +0,0 @@
-commit 256e249566d8
-Author: Christoph Kerschbaumer <ckerschb@christophkerschbaumer.com>
-Date: Fri Aug 4 14:11:17 2017 +0200
-
- Bug 1381761 - Treating 'data:' documents as unique, opaque origins should still inherit the CSP. r=smaug,dveditz
----
- caps/moz.build | 1 +
- caps/nsScriptSecurityManager.cpp | 96 +++++++++++++++++++++++++---------------
- 2 files changed, 62 insertions(+), 35 deletions(-)
-
-diff --git caps/moz.build caps/moz.build
-index 46331e93f097..af369e3268e0 100644
---- caps/moz.build
-+++ caps/moz.build
-@@ -56,6 +56,7 @@ LOCAL_INCLUDES += [
- '/docshell/base',
- '/dom/base',
- '/js/xpconnect/src',
-+ '/netwerk/base',
- ]
-
- if CONFIG['ENABLE_TESTS']:
-diff --git caps/nsScriptSecurityManager.cpp caps/nsScriptSecurityManager.cpp
-index a930b324a6a2..90695ebd126f 100644
---- caps/nsScriptSecurityManager.cpp
-+++ caps/nsScriptSecurityManager.cpp
-@@ -45,6 +45,7 @@
- #include "nsIWindowWatcher.h"
- #include "nsIConsoleService.h"
- #include "nsIObserverService.h"
-+#include "nsIOService.h"
- #include "nsIContent.h"
- #include "nsDOMJSUtils.h"
- #include "nsAboutProtocolUtils.h"
-@@ -265,6 +266,61 @@ nsScriptSecurityManager::GetChannelResultPrincipalIfNotSandboxed(nsIChannel* aCh
- /*aIgnoreSandboxing*/ true);
- }
-
-+static void
-+InheritAndSetCSPOnPrincipalIfNeeded(nsIChannel* aChannel, nsIPrincipal* aPrincipal)
-+{
-+ // loading a data: URI into an iframe, or loading frame[srcdoc] need
-+ // to inherit the CSP (see Bug 1073952, 1381761).
-+ MOZ_ASSERT(aChannel && aPrincipal, "need a valid channel and principal");
-+ if (!aChannel) {
-+ return;
-+ }
-+
-+ nsCOMPtr<nsILoadInfo> loadInfo = aChannel->GetLoadInfo();
-+ if (!loadInfo ||
-+ loadInfo->GetExternalContentPolicyType() != nsIContentPolicy::TYPE_SUBDOCUMENT) {
-+ return;
-+ }
-+
-+ nsCOMPtr<nsIURI> uri;
-+ nsresult rv = aChannel->GetURI(getter_AddRefs(uri));
-+ NS_ENSURE_SUCCESS_VOID(rv);
-+ nsAutoCString URISpec;
-+ rv = uri->GetSpec(URISpec);
-+ NS_ENSURE_SUCCESS_VOID(rv);
-+
-+ bool isSrcDoc = URISpec.EqualsLiteral("about:srcdoc");
-+ bool isData = (NS_SUCCEEDED(uri->SchemeIs("data", &isData)) && isData);
-+
-+ if (!isSrcDoc && !isData) {
-+ return;
-+ }
-+
-+ nsCOMPtr<nsIPrincipal> principalToInherit = loadInfo->PrincipalToInherit();
-+ if (!principalToInherit) {
-+ principalToInherit = loadInfo->TriggeringPrincipal();
-+ }
-+ nsCOMPtr<nsIContentSecurityPolicy> originalCSP;
-+ principalToInherit->GetCsp(getter_AddRefs(originalCSP));
-+ if (!originalCSP) {
-+ return;
-+ }
-+
-+ // if the principalToInherit had a CSP, add it to the before
-+ // created NullPrincipal (unless it already has one)
-+ MOZ_ASSERT(aPrincipal->GetIsNullPrincipal(),
-+ "inheriting the CSP only valid for NullPrincipal");
-+ nsCOMPtr<nsIContentSecurityPolicy> nullPrincipalCSP;
-+ aPrincipal->GetCsp(getter_AddRefs(nullPrincipalCSP));
-+ if (nullPrincipalCSP) {
-+ MOZ_ASSERT(nullPrincipalCSP == originalCSP,
-+ "There should be no other CSP here.");
-+ // CSPs are equal, no need to set it again.
-+ return;
-+ }
-+ aPrincipal->SetCsp(originalCSP);
-+}
-+
- nsresult
- nsScriptSecurityManager::GetChannelResultPrincipal(nsIChannel* aChannel,
- nsIPrincipal** aPrincipal,
-@@ -295,40 +351,7 @@ nsScriptSecurityManager::GetChannelResultPrincipal(nsIChannel* aChannel,
- if (!aIgnoreSandboxing && loadInfo->GetLoadingSandboxed()) {
- MOZ_ALWAYS_TRUE(NS_SUCCEEDED(loadInfo->GetSandboxedLoadingPrincipal(aPrincipal)));
- MOZ_ASSERT(*aPrincipal);
-- // if the new NullPrincipal (above) loads an iframe[srcdoc], we
-- // need to inherit an existing CSP to avoid bypasses (bug 1073952).
-- // We continue inheriting for nested frames with e.g., data: URLs.
-- if (loadInfo->GetExternalContentPolicyType() == nsIContentPolicy::TYPE_SUBDOCUMENT) {
-- nsCOMPtr<nsIURI> uri;
-- aChannel->GetURI(getter_AddRefs(uri));
-- nsAutoCString URISpec;
-- uri->GetSpec(URISpec);
-- bool isData = (NS_SUCCEEDED(uri->SchemeIs("data", &isData)) && isData);
-- if (URISpec.EqualsLiteral("about:srcdoc") || isData) {
-- nsCOMPtr<nsIPrincipal> principalToInherit = loadInfo->PrincipalToInherit();
-- if (!principalToInherit) {
-- principalToInherit = loadInfo->TriggeringPrincipal();
-- }
-- nsCOMPtr<nsIContentSecurityPolicy> originalCSP;
-- principalToInherit->GetCsp(getter_AddRefs(originalCSP));
-- if (originalCSP) {
-- // if the principalToInherit had a CSP,
-- // add it to the newly created NullPrincipal
-- // (unless it already has one)
-- nsCOMPtr<nsIContentSecurityPolicy> nullPrincipalCSP;
-- (*aPrincipal)->GetCsp(getter_AddRefs(nullPrincipalCSP));
-- if (nullPrincipalCSP) {
-- MOZ_ASSERT(nullPrincipalCSP == originalCSP,
-- "There should be no other CSP here.");
-- // CSPs are equal, no need to set it again.
-- return NS_OK;
-- } else {
-- nsresult rv = (*aPrincipal)->SetCsp(originalCSP);
-- NS_ENSURE_SUCCESS(rv, rv);
-- }
-- }
-- }
-- }
-+ InheritAndSetCSPOnPrincipalIfNeeded(aChannel, *aPrincipal);
- return NS_OK;
- }
-
-@@ -376,7 +399,10 @@ nsScriptSecurityManager::GetChannelResultPrincipal(nsIChannel* aChannel,
- }
- }
- }
-- return GetChannelURIPrincipal(aChannel, aPrincipal);
-+ nsresult rv = GetChannelURIPrincipal(aChannel, aPrincipal);
-+ NS_ENSURE_SUCCESS(rv, rv);
-+ InheritAndSetCSPOnPrincipalIfNeeded(aChannel, *aPrincipal);
-+ return NS_OK;
- }
-
- /* The principal of the URI that this channel is loading. This is never
-
-commit 9427f1bbd826
-Author: Christoph Kerschbaumer <ckerschb@christophkerschbaumer.com>
-Date: Fri Aug 4 14:10:21 2017 +0200
-
- Bug 1381761 - Convert test browser_911547.js to comply with new data: URI inheritance model. r=dveditz
----
- .../components/sessionstore/test/browser_911547.js | 47 ++++++++++++++++------
- .../sessionstore/test/browser_911547_sample.html | 6 +--
- 2 files changed, 37 insertions(+), 16 deletions(-)
-
-diff --git browser/components/sessionstore/test/browser_911547.js browser/components/sessionstore/test/browser_911547.js
-index f0da70ed8f8c..cb95ddad7f2a 100644
---- browser/components/sessionstore/test/browser_911547.js
-+++ browser/components/sessionstore/test/browser_911547.js
-@@ -1,11 +1,17 @@
- /* Any copyright is dedicated to the Public Domain.
- http://creativecommons.org/publicdomain/zero/1.0/ */
-
--// This tests that session restore component does restore the right content
--// security policy with the document.
--// The policy being tested disallows inline scripts
-+// This test is two fold:
-+// a) if security.data_uri.unique_opaque_origin == false, then
-+// this tests that session restore component does restore the right
-+// content security policy with the document. (The policy being
-+// tested disallows inline scripts).
-+// b) if security.data_uri.unique_opaque_origin == true, then
-+// this tests that data: URIs do not inherit the CSP from
-+// it's enclosing context.
-
- add_task(async function test() {
-+ let dataURIPref = Services.prefs.getBoolPref("security.data_uri.unique_opaque_origin");
- // create a tab that has a CSP
- let testURL = "http://mochi.test:8888/browser/browser/components/sessionstore/test/browser_911547_sample.html";
- let tab = gBrowser.selectedTab = BrowserTestUtils.addTab(gBrowser, testURL);
-@@ -16,23 +22,33 @@ add_task(async function test() {
-
- // this is a baseline to ensure CSP is active
- // attempt to inject and run a script via inline (pre-restore, allowed)
-- await injectInlineScript(browser, `document.getElementById("test_id").value = "fail";`);
-+ await injectInlineScript(browser, `document.getElementById("test_id1").value = "id1_modified";`);
-
- let loadedPromise = promiseBrowserLoaded(browser);
- await ContentTask.spawn(browser, null, function() {
-- is(content.document.getElementById("test_id").value, "ok",
-+ is(content.document.getElementById("test_id1").value, "id1_initial",
- "CSP should block the inline script that modifies test_id");
-
-- // attempt to click a link to a data: URI (will inherit the CSP of the
-- // origin document) and navigate to the data URI in the link.
-+
-+ // (a) if security.data_uri.unique_opaque_origin == false:
-+ // attempt to click a link to a data: URI (will inherit the CSP of
-+ // the origin document) and navigate to the data URI in the link.
-+ // (b) if security.data_uri.unique_opaque_origin == true:
-+ // attempt to click a link to a data: URI (will *not* inherit the CSP of
-+ // the origin document) and navigate to the data URI in the link.
- content.document.getElementById("test_data_link").click();
- });
-
- await loadedPromise;
-
-- await ContentTask.spawn(browser, null, function() {
-- is(content.document.getElementById("test_id2").value, "ok",
-- "CSP should block the script loaded by the clicked data URI");
-+ await ContentTask.spawn(browser, {dataURIPref}, function( {dataURIPref}) { // eslint-disable-line
-+ if (dataURIPref) {
-+ is(content.document.getElementById("test_id2").value, "id2_modified",
-+ "data: URI should *not* inherit the CSP of the enclosing context");
-+ } else {
-+ is(content.document.getElementById("test_id2").value, "id2_initial",
-+ "CSP should block the script loaded by the clicked data URI");
-+ }
- });
-
- // close the tab
-@@ -43,9 +59,14 @@ add_task(async function test() {
- await promiseTabRestored(tab);
- browser = tab.linkedBrowser;
-
-- await ContentTask.spawn(browser, null, function() {
-- is(content.document.getElementById("test_id2").value, "ok",
-- "CSP should block the script loaded by the clicked data URI after restore");
-+ await ContentTask.spawn(browser, {dataURIPref}, function({dataURIPref}) { // eslint-disable-line
-+ if (dataURIPref) {
-+ is(content.document.getElementById("test_id2").value, "id2_modified",
-+ "data: URI should *not* inherit the CSP of the enclosing context");
-+ } else {
-+ is(content.document.getElementById("test_id2").value, "id2_initial",
-+ "CSP should block the script loaded by the clicked data URI after restore");
-+ }
- });
-
- // clean up
-diff --git browser/components/sessionstore/test/browser_911547_sample.html browser/components/sessionstore/test/browser_911547_sample.html
-index ccc2011593d4..73cb99ee41f1 100644
---- browser/components/sessionstore/test/browser_911547_sample.html
-+++ browser/components/sessionstore/test/browser_911547_sample.html
-@@ -8,12 +8,12 @@
-
- <!--
- this element gets modified by an injected script;
-- that script should be blocked by CSP.
-+ that script should be blocked by CSP if security.data_uri.unique_opaque_origin == false;
- Inline scripts can modify it, but not data uris.
- -->
-- <input type="text" id="test_id" value="ok">
-+ <input type="text" id="test_id1" value="id1_initial">
-
-- <a id="test_data_link" href="data:text/html;charset=utf-8,<input type='text' id='test_id2' value='ok'/> <script>document.getElementById('test_id2').value = 'fail';</script>">Test Link</a>
-+ <a id="test_data_link" href="data:text/html;charset=utf-8,<input type='text' id='test_id2' value='id2_initial'/> <script>document.getElementById('test_id2').value = 'id2_modified';</script>">Test Link</a>
-
- </body>
- </html>
-
-commit 8b999864f0bb
-Author: Christoph Kerschbaumer <ckerschb@christophkerschbaumer.com>
-Date: Fri Aug 4 14:10:38 2017 +0200
-
- Bug 1381761 - Test data: URIs inherit the CSP even if treated as unique, opaque origins. r=dveditz
----
- .../test/csp/file_data_csp_inheritance.html | 21 +++++++++++++
- dom/security/test/csp/mochitest.ini | 2 ++
- .../test/csp/test_data_csp_inheritance.html | 34 ++++++++++++++++++++++
- 3 files changed, 57 insertions(+)
-
-diff --git dom/security/test/csp/file_data_csp_inheritance.html dom/security/test/csp/file_data_csp_inheritance.html
-new file mode 100644
-index 000000000000..299c30255aa6
---- /dev/null
-+++ dom/security/test/csp/file_data_csp_inheritance.html
-@@ -0,0 +1,21 @@
-+<!DOCTYPE HTML>
-+<html>
-+<head>
-+ <title>Bug 1381761 - Treating 'data:' documents as unique, opaque origins should still inherit the CSP</title>
-+ <meta charset="utf-8">
-+ <meta http-equiv="Content-Security-Policy" content= "img-src 'none'"/>
-+</head>
-+<body>
-+<iframe id="dataFrame" src="data:text/html,<body>should inherit csp</body>"></iframe>
-+
-+<script type="application/javascript">
-+ // get the csp in JSON notation from the principal
-+ var frame = document.getElementById("dataFrame");
-+ var principal = SpecialPowers.wrap(frame.contentDocument).nodePrincipal;
-+ var cspJSON = principal.cspJSON;
-+ var result = principal.cspJSON ? "dataInheritsCSP" : "dataDoesNotInheritCSP";
-+ window.parent.postMessage({result}, "*");
-+</script>
-+
-+</body>
-+</html>
-diff --git dom/security/test/csp/mochitest.ini dom/security/test/csp/mochitest.ini
-index ba391ad59799..09f80b2969d7 100644
---- dom/security/test/csp/mochitest.ini
-+++ dom/security/test/csp/mochitest.ini
-@@ -217,6 +217,7 @@ support-files =
- file_ignore_xfo.html^headers^
- file_ro_ignore_xfo.html
- file_ro_ignore_xfo.html^headers^
-+ file_data_csp_inheritance.html
- file_report_font_cache-1.html
- file_report_font_cache-2.html
- file_report_font_cache-2.html^headers^
-@@ -308,4 +309,5 @@ tags = mcb
- [test_websocket_self.html]
- skip-if = toolkit == 'android'
- [test_ignore_xfo.html]
-+[test_data_csp_inheritance.html]
- [test_data_csp_merge.html]
-diff --git dom/security/test/csp/test_data_csp_inheritance.html dom/security/test/csp/test_data_csp_inheritance.html
-new file mode 100644
-index 000000000000..3afc4f7c02bc
---- /dev/null
-+++ dom/security/test/csp/test_data_csp_inheritance.html
-@@ -0,0 +1,34 @@
-+<!DOCTYPE HTML>
-+<html>
-+<head>
-+ <title>Bug 1381761 - Treating 'data:' documents as unique, opaque origins should still inherit the CSP</title>
-+ <!-- Including SimpleTest.js so we can use waitForExplicitFinish !-->
-+ <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
-+ <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
-+</head>
-+<body>
-+<iframe style="width:100%;" id="testframe"></iframe>
-+
-+<script class="testbody" type="text/javascript">
-+
-+SimpleTest.waitForExplicitFinish();
-+
-+/* Description of the test:
-+ * We load an iframe using a meta CSP which includes another iframe
-+ * using a data: URI. We make sure the CSP gets inherited into
-+ * the data: URI iframe.
-+ */
-+
-+window.addEventListener("message", receiveMessage);
-+function receiveMessage(event) {
-+ window.removeEventListener("message", receiveMessage);
-+ is(event.data.result, "dataInheritsCSP",
-+ "data: URI iframe inherits CSP from including context");
-+ SimpleTest.finish();
-+}
-+
-+document.getElementById("testframe").src = "file_data_csp_inheritance.html";
-+
-+</script>
-+</body>
-+</html>
diff --git a/www/firefox/files/patch-bug1383019 b/www/firefox/files/patch-bug1383019
deleted file mode 100644
index ed84c172b277..000000000000
--- a/www/firefox/files/patch-bug1383019
+++ /dev/null
@@ -1,200 +0,0 @@
-commit 6b3da0609f95
-Author: Byron Campen [:bwc] <docfaraday@gmail.com>
-Date: Thu Sep 14 12:19:24 2017 -0500
-
- Bug 1383019: Move more logic under the protection of nsTimerImpl::mMutex, and simplify. r=froydnj, a=abillings
-
- MozReview-Commit-ID: JjYScKwyika
-
- --HG--
- extra : rebase_source : a5a8a17f86459ace51d9250454bd4cf1433130b0
----
- xpcom/threads/TimerThread.cpp | 12 ++++++----
- xpcom/threads/TimerThread.h | 32 -------------------------
- xpcom/threads/nsTimerImpl.cpp | 56 +++++++++++++++++++++----------------------
- xpcom/threads/nsTimerImpl.h | 5 ++--
- 4 files changed, 36 insertions(+), 69 deletions(-)
-
-diff --git xpcom/threads/TimerThread.cpp xpcom/threads/TimerThread.cpp
-index b91b27b2073a..99a40d91b3c0 100644
---- xpcom/threads/TimerThread.cpp
-+++ xpcom/threads/TimerThread.cpp
-@@ -331,7 +331,7 @@ TimerThread::Shutdown()
- return NS_ERROR_NOT_INITIALIZED;
- }
-
-- nsTArray<UniquePtr<Entry>> timers;
-+ nsTArray<RefPtr<nsTimerImpl>> timers;
- {
- // lock scope
- MonitorAutoLock lock(mMonitor);
-@@ -350,12 +350,14 @@ TimerThread::Shutdown()
- // might potentially call some code reentering the same lock
- // that leads to unexpected behavior or deadlock.
- // See bug 422472.
-- mTimers.SwapElements(timers);
-+ for (const UniquePtr<Entry>& entry : mTimers) {
-+ timers.AppendElement(entry->Take());
-+ }
-+
-+ mTimers.Clear();
- }
-
-- uint32_t timersCount = timers.Length();
-- for (uint32_t i = 0; i < timersCount; i++) {
-- RefPtr<nsTimerImpl> timer = timers[i]->Take();
-+ for (const RefPtr<nsTimerImpl>& timer : timers) {
- if (timer) {
- timer->Cancel();
- }
-diff --git xpcom/threads/TimerThread.h xpcom/threads/TimerThread.h
-index f65c501c50e8..6610f5bf387b 100644
---- xpcom/threads/TimerThread.h
-+++ xpcom/threads/TimerThread.h
-@@ -129,36 +129,4 @@ private:
- uint32_t mAllowedEarlyFiringMicroseconds;
- };
-
--struct TimerAdditionComparator
--{
-- TimerAdditionComparator(const mozilla::TimeStamp& aNow,
-- nsTimerImpl* aTimerToInsert) :
-- now(aNow)
--#ifdef DEBUG
-- , timerToInsert(aTimerToInsert)
--#endif
-- {
-- }
--
-- bool LessThan(nsTimerImpl* aFromArray, nsTimerImpl* aNewTimer) const
-- {
-- MOZ_ASSERT(aNewTimer == timerToInsert, "Unexpected timer ordering");
--
-- // Skip any overdue timers.
-- return aFromArray->mTimeout <= now ||
-- aFromArray->mTimeout <= aNewTimer->mTimeout;
-- }
--
-- bool Equals(nsTimerImpl* aFromArray, nsTimerImpl* aNewTimer) const
-- {
-- return false;
-- }
--
--private:
-- const mozilla::TimeStamp& now;
--#ifdef DEBUG
-- const nsTimerImpl* const timerToInsert;
--#endif
--};
--
- #endif /* TimerThread_h___ */
-diff --git xpcom/threads/nsTimerImpl.cpp xpcom/threads/nsTimerImpl.cpp
-index f6803791fe45..735271af089a 100644
---- xpcom/threads/nsTimerImpl.cpp
-+++ xpcom/threads/nsTimerImpl.cpp
-@@ -133,16 +133,8 @@ nsTimer::Release(void)
- NS_LOG_RELEASE(this, count, "nsTimer");
-
- if (count == 1) {
-- if (!mImpl->CancelCheckIfFiring()) {
-- // Last ref, in nsTimerImpl::mITimer. Make sure the cycle is broken.
-- // (when Cancel fails, nsTimerImpl::Fire is in progress, which has grabbed
-- // another ref to the nsITimer since we checked the value of mRefCnt
-- // above)
-- // If there is a nsTimerEvent in a queue for this timer, the nsTimer will
-- // live until that event pops, otherwise the nsTimerImpl will go away and
-- // the nsTimer along with it.
-- mImpl = nullptr;
-- }
-+ // Last ref, in nsTimerImpl::mITimer. Make sure the cycle is broken.
-+ mImpl->CancelImpl(true);
- } else if (count == 0) {
- delete this;
- }
-@@ -322,31 +314,37 @@ nsTimerImpl::Init(nsIObserver* aObserver, uint32_t aDelay, uint32_t aType)
- return InitCommon(aDelay, aType, mozilla::Move(cb));
- }
-
--bool
--nsTimerImpl::CancelCheckIfFiring()
-+nsresult
-+nsTimerImpl::Cancel()
- {
-- Callback cb;
-+ CancelImpl(false);
-+ return NS_OK;
-+}
-
-- MutexAutoLock lock(mMutex);
-+void
-+nsTimerImpl::CancelImpl(bool aClearITimer)
-+{
-+ Callback cbTrash;
-+ RefPtr<nsITimer> timerTrash;
-
-- if (gThread) {
-- gThread->RemoveTimer(this);
-- }
-+ {
-+ MutexAutoLock lock(mMutex);
-+ if (gThread) {
-+ gThread->RemoveTimer(this);
-+ }
-
-- cb.swap(mCallback);
-- ++mGeneration;
-+ cbTrash.swap(mCallback);
-+ ++mGeneration;
-
-- if (mCallbackDuringFire.mType != Callback::Type::Unknown) {
-- return true;
-+ // Don't clear this if we're firing; once Fire returns, we'll get this call
-+ // again.
-+ if (aClearITimer &&
-+ (mCallbackDuringFire.mType == Callback::Type::Unknown)) {
-+ MOZ_RELEASE_ASSERT(mITimer, "mITimer was nulled already! "
-+ "This indicates that someone has messed up the refcount on nsTimer!");
-+ timerTrash.swap(mITimer);
-+ }
- }
-- return false;
--}
--
--nsresult
--nsTimerImpl::Cancel()
--{
-- (void)CancelCheckIfFiring();
-- return NS_OK;
- }
-
- nsresult
-diff --git xpcom/threads/nsTimerImpl.h xpcom/threads/nsTimerImpl.h
-index 4b26cd21d80a..1cb530c0be3d 100644
---- xpcom/threads/nsTimerImpl.h
-+++ xpcom/threads/nsTimerImpl.h
-@@ -56,7 +56,7 @@ public:
- static void Shutdown();
-
- void SetDelayInternal(uint32_t aDelay, TimeStamp aBase = TimeStamp::Now());
-- bool CancelCheckIfFiring();
-+ void CancelImpl(bool aClearITimer);
-
- void Fire(int32_t aGeneration);
-
-@@ -211,7 +211,7 @@ public:
- static double sDeltaSum;
- static double sDeltaSumSquared;
- static double sDeltaNum;
-- const RefPtr<nsITimer> mITimer;
-+ RefPtr<nsITimer> mITimer;
- mozilla::Mutex mMutex;
- Callback mCallback;
- Callback mCallbackDuringFire;
-@@ -225,7 +225,6 @@ public:
-
- friend class TimerThread;
- friend class nsTimerEvent;
-- friend struct TimerAdditionComparator;
-
- NS_DECL_THREADSAFE_ISUPPORTS
- NS_FORWARD_SAFE_NSITIMER(mImpl);
diff --git a/www/firefox/files/patch-bug1384121 b/www/firefox/files/patch-bug1384121
deleted file mode 100644
index 94a261585850..000000000000
--- a/www/firefox/files/patch-bug1384121
+++ /dev/null
@@ -1,218 +0,0 @@
-commit 485ed2f2b015
-Author: Jan de Mooij <jdemooij@mozilla.com>
-Date: Mon Sep 18 15:08:44 2017 +0200
-
- Bug 1384121 part 1 - Don't sweep ObjectGroups under IC helper functions. r=bhackett
----
- js/src/jit/IonCacheIRCompiler.cpp | 4 ++--
- js/src/vm/ObjectGroup.h | 2 ++
- js/src/vm/TypeInference-inl.h | 29 ++++++++++++++++++++++-------
- js/src/vm/UnboxedObject.cpp | 2 +-
- 4 files changed, 27 insertions(+), 10 deletions(-)
-
-diff --git js/src/jit/IonCacheIRCompiler.cpp js/src/jit/IonCacheIRCompiler.cpp
-index b11aed7966b6..bbfbdae57b12 100644
---- js/src/jit/IonCacheIRCompiler.cpp
-+++ js/src/jit/IonCacheIRCompiler.cpp
-@@ -1324,9 +1324,9 @@ IonCacheIRCompiler::emitCallStringSplitResult()
- static bool
- GroupHasPropertyTypes(ObjectGroup* group, jsid* id, Value* v)
- {
-- if (group->unknownProperties())
-+ if (group->unknownPropertiesDontCheckGeneration())
- return true;
-- HeapTypeSet* propTypes = group->maybeGetProperty(*id);
-+ HeapTypeSet* propTypes = group->maybeGetPropertyDontCheckGeneration(*id);
- if (!propTypes)
- return true;
- if (!propTypes->nonConstantProperty())
-diff --git js/src/vm/ObjectGroup.h js/src/vm/ObjectGroup.h
-index 237b5a152576..0eba71ee084f 100644
---- js/src/vm/ObjectGroup.h
-+++ js/src/vm/ObjectGroup.h
-@@ -390,6 +390,7 @@ class ObjectGroup : public gc::TenuredCell
-
- /* Get a property only if it already exists. */
- MOZ_ALWAYS_INLINE HeapTypeSet* maybeGetProperty(jsid id);
-+ MOZ_ALWAYS_INLINE HeapTypeSet* maybeGetPropertyDontCheckGeneration(jsid id);
-
- /*
- * Iterate through the group's properties. getPropertyCount overapproximates
-@@ -471,6 +472,7 @@ class ObjectGroup : public gc::TenuredCell
- }
-
- inline uint32_t basePropertyCount();
-+ inline uint32_t basePropertyCountDontCheckGeneration();
-
- private:
- inline void setBasePropertyCount(uint32_t count);
-diff --git js/src/vm/TypeInference-inl.h js/src/vm/TypeInference-inl.h
-index f7cd3459ef19..f2b0b9a52fbc 100644
---- js/src/vm/TypeInference-inl.h
-+++ js/src/vm/TypeInference-inl.h
-@@ -369,10 +369,10 @@ TypeMonitorCall(JSContext* cx, const js::CallArgs& args, bool constructing)
- MOZ_ALWAYS_INLINE bool
- TrackPropertyTypes(JSObject* obj, jsid id)
- {
-- if (obj->hasLazyGroup() || obj->group()->unknownProperties())
-+ if (obj->hasLazyGroup() || obj->group()->unknownPropertiesDontCheckGeneration())
- return false;
-
-- if (obj->isSingleton() && !obj->group()->maybeGetProperty(id))
-+ if (obj->isSingleton() && !obj->group()->maybeGetPropertyDontCheckGeneration(id))
- return false;
-
- return true;
-@@ -410,7 +410,7 @@ HasTrackedPropertyType(JSObject* obj, jsid id, TypeSet::Type type)
- MOZ_ASSERT(id == IdToTypeId(id));
- MOZ_ASSERT(TrackPropertyTypes(obj, id));
-
-- if (HeapTypeSet* types = obj->group()->maybeGetProperty(id)) {
-+ if (HeapTypeSet* types = obj->group()->maybeGetPropertyDontCheckGeneration(id)) {
- if (!types->hasType(type))
- return false;
- // Non-constant properties are only relevant for singleton objects.
-@@ -1074,10 +1074,18 @@ TypeSet::getObjectClass(unsigned i) const
- // ObjectGroup
- /////////////////////////////////////////////////////////////////////
-
-+inline uint32_t
-+ObjectGroup::basePropertyCountDontCheckGeneration()
-+{
-+ uint32_t flags = flagsDontCheckGeneration();
-+ return (flags & OBJECT_FLAG_PROPERTY_COUNT_MASK) >> OBJECT_FLAG_PROPERTY_COUNT_SHIFT;
-+}
-+
- inline uint32_t
- ObjectGroup::basePropertyCount()
- {
-- return (flags() & OBJECT_FLAG_PROPERTY_COUNT_MASK) >> OBJECT_FLAG_PROPERTY_COUNT_SHIFT;
-+ maybeSweep(nullptr);
-+ return basePropertyCountDontCheckGeneration();
- }
-
- inline void
-@@ -1134,14 +1142,14 @@ ObjectGroup::getProperty(JSContext* cx, JSObject* obj, jsid id)
- }
-
- MOZ_ALWAYS_INLINE HeapTypeSet*
--ObjectGroup::maybeGetProperty(jsid id)
-+ObjectGroup::maybeGetPropertyDontCheckGeneration(jsid id)
- {
- MOZ_ASSERT(JSID_IS_VOID(id) || JSID_IS_EMPTY(id) || JSID_IS_STRING(id) || JSID_IS_SYMBOL(id));
- MOZ_ASSERT_IF(!JSID_IS_EMPTY(id), id == IdToTypeId(id));
-- MOZ_ASSERT(!unknownProperties());
-+ MOZ_ASSERT(!unknownPropertiesDontCheckGeneration());
-
- Property* prop = TypeHashSet::Lookup<jsid, Property, Property>
-- (propertySet, basePropertyCount(), id);
-+ (propertySet, basePropertyCountDontCheckGeneration(), id);
-
- if (!prop)
- return nullptr;
-@@ -1150,6 +1158,13 @@ ObjectGroup::maybeGetProperty(jsid id)
- return &prop->types;
- }
-
-+MOZ_ALWAYS_INLINE HeapTypeSet*
-+ObjectGroup::maybeGetProperty(jsid id)
-+{
-+ maybeSweep(nullptr);
-+ return maybeGetPropertyDontCheckGeneration(id);
-+}
-+
- inline unsigned
- ObjectGroup::getPropertyCount()
- {
-diff --git js/src/vm/UnboxedObject.cpp js/src/vm/UnboxedObject.cpp
-index c155b7dc47c9..4e007489a67e 100644
---- js/src/vm/UnboxedObject.cpp
-+++ js/src/vm/UnboxedObject.cpp
-@@ -363,7 +363,7 @@ UnboxedPlainObject::ensureExpando(JSContext* cx, Handle<UnboxedPlainObject*> obj
- bool
- UnboxedPlainObject::containsUnboxedOrExpandoProperty(JSContext* cx, jsid id) const
- {
-- if (layout().lookup(id))
-+ if (layoutDontCheckGeneration().lookup(id))
- return true;
-
- if (maybeExpando() && maybeExpando()->containsShapeOrElement(cx, id))
-commit e240cf665f74
-Author: Jan de Mooij <jdemooij@mozilla.com>
-Date: Wed Sep 20 12:13:54 2017 +0200
-
- Bug 1384121 part 2 - Add asserts to catch similar bugs and fix some false positives. r=nbp
----
- js/src/jit/Bailouts.cpp | 4 ----
- js/src/jit/JSJitFrameIter.cpp | 2 ++
- js/src/jit/VMFunctions.cpp | 1 -
- js/src/jit/arm/Trampoline-arm.cpp | 9 ++++++---
- js/src/jit/arm64/Trampoline-arm64.cpp | 9 ++++++---
- js/src/jit/mips32/Trampoline-mips32.cpp | 9 ++++++---
- js/src/jit/mips64/Trampoline-mips64.cpp | 9 ++++++---
- js/src/jit/x64/Trampoline-x64.cpp | 9 ++++++---
- js/src/jit/x86/Trampoline-x86.cpp | 9 ++++++---
- js/src/vm/ObjectGroup-inl.h | 1 +
- js/src/vm/Stack.cpp | 2 ++
- js/src/vm/TypeInference.cpp | 3 +++
- 12 files changed, 44 insertions(+), 23 deletions(-)
-
-diff --git js/src/jit/JSJitFrameIter.cpp js/src/jit/JSJitFrameIter.cpp
-index 3774b327d21c..ae76bc2abaf0 100644
---- js/src/jit/JitFrameIterator.cpp
-+++ js/src/jit/JitFrameIterator.cpp
-@@ -25,6 +25,8 @@ JSJitFrameIter::JSJitFrameIter(const JitActivation* activation)
- current_ = activation_->bailoutData()->fp();
- frameSize_ = activation_->bailoutData()->topFrameSize();
- type_ = JitFrame_Bailout;
-+ } else {
-+ MOZ_ASSERT(!TlsContext.get()->inUnsafeCallWithABI);
- }
- }
-
-diff --git js/src/vm/ObjectGroup-inl.h js/src/vm/ObjectGroup-inl.h
-index 7e023ecbad8e..d7caa63d8725 100644
---- js/src/vm/ObjectGroup-inl.h
-+++ js/src/vm/ObjectGroup-inl.h
-@@ -16,6 +16,7 @@ ObjectGroup::needsSweep()
- {
- // Note: this can be called off thread during compacting GCs, in which case
- // nothing will be running on the active thread.
-+ MOZ_ASSERT(!TlsContext.get()->inUnsafeCallWithABI);
- return generation() != zoneFromAnyThread()->types.generation;
- }
-
-diff --git js/src/vm/Stack.cpp js/src/vm/Stack.cpp
-index d3c0038db5ca..0406195abd56 100644
---- js/src/vm/Stack.cpp
-+++ js/src/vm/Stack.cpp
-@@ -605,6 +605,8 @@ FrameIter::popInterpreterFrame()
- void
- FrameIter::settleOnActivation()
- {
-+ MOZ_ASSERT(!data_.cx_->inUnsafeCallWithABI);
-+
- while (true) {
- if (data_.activations_.done()) {
- data_.state_ = DONE;
-diff --git js/src/vm/TypeInference.cpp js/src/vm/TypeInference.cpp
-index f0562a4355f8..eba18e34397e 100644
---- js/src/vm/TypeInference.cpp
-+++ js/src/vm/TypeInference.cpp
-@@ -4428,6 +4428,8 @@ ObjectGroup::sweep(AutoClearTypeInferenceStateOnOOM* oom)
- /* static */ void
- JSScript::maybeSweepTypes(AutoClearTypeInferenceStateOnOOM* oom)
- {
-+ MOZ_ASSERT(!TlsContext.get()->inUnsafeCallWithABI);
-+
- if (!types_ || typesGeneration() == zone()->types.generation)
- return;
-
-@@ -4611,6 +4613,7 @@ AutoClearTypeInferenceStateOnOOM::AutoClearTypeInferenceStateOnOOM(Zone* zone)
- : zone(zone), oom(false)
- {
- MOZ_RELEASE_ASSERT(CurrentThreadCanAccessZone(zone));
-+ MOZ_ASSERT(!TlsContext.get()->inUnsafeCallWithABI);
- zone->types.setSweepingTypes(true);
- }
-
diff --git a/www/firefox/files/patch-bug1384701 b/www/firefox/files/patch-bug1384701
deleted file mode 100644
index 142d5430d266..000000000000
--- a/www/firefox/files/patch-bug1384701
+++ /dev/null
@@ -1,796 +0,0 @@
-diff --git widget/gtk/nsLookAndFeel.cpp widget/gtk/nsLookAndFeel.cpp
-index 6bb3e27c6653..f4c35d82200a 100644
---- widget/gtk/nsLookAndFeel.cpp
-+++ widget/gtk/nsLookAndFeel.cpp
-@@ -29,11 +29,9 @@
-
- #include "mozilla/gfx/2D.h"
-
--#if MOZ_WIDGET_GTK != 2
- #include <cairo-gobject.h>
- #include "WidgetStyleCache.h"
- #include "prenv.h"
--#endif
-
- using mozilla::LookAndFeel;
-
-@@ -49,9 +47,6 @@ using mozilla::LookAndFeel;
-
- nsLookAndFeel::nsLookAndFeel()
- : nsXPLookAndFeel(),
--#if (MOZ_WIDGET_GTK == 2)
-- mStyle(nullptr),
--#endif
- mDefaultFontCached(false), mButtonFontCached(false),
- mFieldFontCached(false), mMenuFontCached(false),
- mInitialized(false)
-@@ -66,12 +61,8 @@ nsLookAndFeel::NativeInit()
-
- nsLookAndFeel::~nsLookAndFeel()
- {
--#if (MOZ_WIDGET_GTK == 2)
-- g_object_unref(mStyle);
--#endif
- }
-
--#if MOZ_WIDGET_GTK != 2
- // Modifies color |*aDest| as if a pattern of color |aSource| was painted with
- // CAIRO_OPERATOR_OVER to a surface with color |*aDest|.
- static void
-@@ -228,42 +219,19 @@ GetBorderColors(GtkStyleContext* aContext,
- *aDarkColor = GDK_RGBA_TO_NS_RGBA(darkColor);
- return ret;
- }
--#endif
-
- nsresult
- nsLookAndFeel::NativeGetColor(ColorID aID, nscolor& aColor)
- {
- EnsureInit();
-
--#if (MOZ_WIDGET_GTK == 3)
- GdkRGBA gdk_color;
--#endif
- nsresult res = NS_OK;
-
- switch (aID) {
- // These colors don't seem to be used for anything anymore in Mozilla
- // (except here at least TextSelectBackground and TextSelectForeground)
- // The CSS2 colors below are used.
--#if (MOZ_WIDGET_GTK == 2)
-- case eColorID_WindowBackground:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->base[GTK_STATE_NORMAL]);
-- break;
-- case eColorID_WindowForeground:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->text[GTK_STATE_NORMAL]);
-- break;
-- case eColorID_WidgetBackground:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->bg[GTK_STATE_NORMAL]);
-- break;
-- case eColorID_WidgetForeground:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->fg[GTK_STATE_NORMAL]);
-- break;
-- case eColorID_WidgetSelectBackground:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->bg[GTK_STATE_SELECTED]);
-- break;
-- case eColorID_WidgetSelectForeground:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->fg[GTK_STATE_SELECTED]);
-- break;
--#else
- case eColorID_WindowBackground:
- case eColorID_WidgetBackground:
- case eColorID_TextBackground:
-@@ -303,35 +271,12 @@ nsLookAndFeel::NativeGetColor(ColorID aID, nscolor& aColor)
- case eColorID__moz_html_cellhighlighttext:
- aColor = sTextSelectedText;
- break;
--#endif
- case eColorID_Widget3DHighlight:
- aColor = NS_RGB(0xa0,0xa0,0xa0);
- break;
- case eColorID_Widget3DShadow:
- aColor = NS_RGB(0x40,0x40,0x40);
- break;
--#if (MOZ_WIDGET_GTK == 2)
-- case eColorID_TextBackground:
-- // not used?
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->base[GTK_STATE_NORMAL]);
-- break;
-- case eColorID_TextForeground:
-- // not used?
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->text[GTK_STATE_NORMAL]);
-- break;
-- case eColorID_TextSelectBackground:
-- case eColorID_IMESelectedRawTextBackground:
-- case eColorID_IMESelectedConvertedTextBackground:
-- // still used
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->base[GTK_STATE_SELECTED]);
-- break;
-- case eColorID_TextSelectForeground:
-- case eColorID_IMESelectedRawTextForeground:
-- case eColorID_IMESelectedConvertedTextForeground:
-- // still used
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->text[GTK_STATE_SELECTED]);
-- break;
--#endif
- case eColorID_IMERawInputBackground:
- case eColorID_IMEConvertedTextBackground:
- aColor = NS_TRANSPARENT;
-@@ -352,53 +297,6 @@ nsLookAndFeel::NativeGetColor(ColorID aID, nscolor& aColor)
- aColor = NS_RGB(0xff, 0, 0);
- break;
-
--#if (MOZ_WIDGET_GTK == 2)
-- // css2 http://www.w3.org/TR/REC-CSS2/ui.html#system-colors
-- case eColorID_activeborder:
-- // active window border
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->bg[GTK_STATE_NORMAL]);
-- break;
-- case eColorID_activecaption:
-- // active window caption background
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->bg[GTK_STATE_NORMAL]);
-- break;
-- case eColorID_appworkspace:
-- // MDI background color
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->bg[GTK_STATE_NORMAL]);
-- break;
-- case eColorID_background:
-- // desktop background
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->bg[GTK_STATE_NORMAL]);
-- break;
-- case eColorID_captiontext:
-- // text in active window caption, size box, and scrollbar arrow box (!)
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->fg[GTK_STATE_NORMAL]);
-- break;
-- case eColorID_graytext:
-- // disabled text in windows, menus, etc.
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->fg[GTK_STATE_INSENSITIVE]);
-- break;
-- case eColorID_highlight:
-- // background of selected item
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->base[GTK_STATE_SELECTED]);
-- break;
-- case eColorID_highlighttext:
-- // text of selected item
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->text[GTK_STATE_SELECTED]);
-- break;
-- case eColorID_inactiveborder:
-- // inactive window border
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->bg[GTK_STATE_NORMAL]);
-- break;
-- case eColorID_inactivecaption:
-- // inactive window caption
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->bg[GTK_STATE_INSENSITIVE]);
-- break;
-- case eColorID_inactivecaptiontext:
-- // text in inactive window caption
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->fg[GTK_STATE_INSENSITIVE]);
-- break;
--#else
- // css2 http://www.w3.org/TR/REC-CSS2/ui.html#system-colors
- case eColorID_activeborder: {
- // active window border
-@@ -433,7 +331,6 @@ nsLookAndFeel::NativeGetColor(ColorID aID, nscolor& aColor)
- ReleaseStyleContext(style);
- break;
- }
--#endif
- case eColorID_infobackground:
- // tooltip background color
- aColor = sInfoBackground;
-@@ -452,11 +349,7 @@ nsLookAndFeel::NativeGetColor(ColorID aID, nscolor& aColor)
- break;
- case eColorID_scrollbar:
- // scrollbar gray area
--#if (MOZ_WIDGET_GTK == 2)
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->bg[GTK_STATE_ACTIVE]);
--#else
- aColor = sMozScrollbar;
--#endif
- break;
-
- case eColorID_threedlightshadow:
-@@ -465,11 +358,7 @@ nsLookAndFeel::NativeGetColor(ColorID aID, nscolor& aColor)
- case eColorID_threedface:
- case eColorID_buttonface:
- // 3-D face color
--#if (MOZ_WIDGET_GTK == 3)
- aColor = sMozWindowBackground;
--#else
-- aColor = sButtonBackground;
--#endif
- break;
-
- case eColorID_buttontext:
-@@ -491,56 +380,6 @@ nsLookAndFeel::NativeGetColor(ColorID aID, nscolor& aColor)
- aColor = sFrameInnerDarkBorder;
- break;
-
--#if (MOZ_WIDGET_GTK == 2)
-- case eColorID_threeddarkshadow:
-- // 3-D shadow outer edge color
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->black);
-- break;
--
-- case eColorID_window:
-- case eColorID_windowframe:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->bg[GTK_STATE_NORMAL]);
-- break;
--
-- case eColorID_windowtext:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->fg[GTK_STATE_NORMAL]);
-- break;
--
-- case eColorID__moz_eventreerow:
-- case eColorID__moz_field:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->base[GTK_STATE_NORMAL]);
-- break;
-- case eColorID__moz_fieldtext:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->text[GTK_STATE_NORMAL]);
-- break;
-- case eColorID__moz_dialog:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->bg[GTK_STATE_NORMAL]);
-- break;
-- case eColorID__moz_dialogtext:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->fg[GTK_STATE_NORMAL]);
-- break;
-- case eColorID__moz_dragtargetzone:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->bg[GTK_STATE_SELECTED]);
-- break;
-- case eColorID__moz_buttondefault:
-- // default button border color
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->black);
-- break;
-- case eColorID__moz_buttonhoverface:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->bg[GTK_STATE_PRELIGHT]);
-- break;
-- case eColorID__moz_buttonhovertext:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->fg[GTK_STATE_PRELIGHT]);
-- break;
-- case eColorID__moz_cellhighlight:
-- case eColorID__moz_html_cellhighlight:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->base[GTK_STATE_ACTIVE]);
-- break;
-- case eColorID__moz_cellhighlighttext:
-- case eColorID__moz_html_cellhighlighttext:
-- aColor = GDK_COLOR_TO_NS_RGB(mStyle->text[GTK_STATE_ACTIVE]);
-- break;
--#else
- case eColorID_threeddarkshadow:
- // Hardcode to black
- aColor = NS_RGB(0x00,0x00,0x00);
-@@ -574,7 +413,6 @@ nsLookAndFeel::NativeGetColor(ColorID aID, nscolor& aColor)
- case eColorID__moz_buttonhovertext:
- aColor = sButtonHoverText;
- break;
--#endif
- case eColorID__moz_menuhover:
- aColor = sMenuHover;
- break;
-@@ -590,11 +428,6 @@ nsLookAndFeel::NativeGetColor(ColorID aID, nscolor& aColor)
- case eColorID__moz_comboboxtext:
- aColor = sComboBoxText;
- break;
--#if (MOZ_WIDGET_GTK == 2)
-- case eColorID__moz_combobox:
-- aColor = sComboBoxBackground;
-- break;
--#endif
- case eColorID__moz_menubartext:
- aColor = sMenuBarText;
- break;
-@@ -602,11 +435,7 @@ nsLookAndFeel::NativeGetColor(ColorID aID, nscolor& aColor)
- aColor = sMenuBarHoverText;
- break;
- case eColorID__moz_gtk_info_bar_text:
--#if (MOZ_WIDGET_GTK == 3)
- aColor = sInfoBarText;
--#else
-- aColor = sInfoText;
--#endif
- break;
- default:
- /* default color is BLACK */
-@@ -618,27 +447,6 @@ nsLookAndFeel::NativeGetColor(ColorID aID, nscolor& aColor)
- return res;
- }
-
--#if (MOZ_WIDGET_GTK == 2)
--static void darken_gdk_color(GdkColor *src, GdkColor *dest)
--{
-- gdouble red;
-- gdouble green;
-- gdouble blue;
--
-- red = (gdouble) src->red / 65535.0;
-- green = (gdouble) src->green / 65535.0;
-- blue = (gdouble) src->blue / 65535.0;
--
-- red *= 0.93;
-- green *= 0.93;
-- blue *= 0.93;
--
-- dest->red = red * 65535.0;
-- dest->green = green * 65535.0;
-- dest->blue = blue * 65535.0;
--}
--#endif
--
- static int32_t CheckWidgetStyle(GtkWidget* aWidget, const char* aStyle, int32_t aResult) {
- gboolean value = FALSE;
- gtk_widget_style_get(aWidget, aStyle, &value, nullptr);
-@@ -826,14 +634,8 @@ nsLookAndFeel::GetIntImpl(IntID aID, int32_t &aResult)
- res = NS_ERROR_NOT_IMPLEMENTED;
- break;
- case eIntID_TouchEnabled:
--#if MOZ_WIDGET_GTK == 3
- aResult = mozilla::widget::WidgetUtils::IsTouchDeviceSupportPresent();
- break;
--#else
-- aResult = 0;
-- res = NS_ERROR_NOT_IMPLEMENTED;
--#endif
-- break;
- case eIntID_MacGraphiteTheme:
- aResult = 0;
- res = NS_ERROR_NOT_IMPLEMENTED;
-@@ -905,24 +707,20 @@ nsLookAndFeel::GetFloatImpl(FloatID aID, float &aResult)
- }
-
- static void
--GetSystemFontInfo(GtkWidget *aWidget,
-+GetSystemFontInfo(GtkStyleContext *aStyle,
- nsString *aFontName,
- gfxFontStyle *aFontStyle)
- {
-- GtkSettings *settings = gtk_widget_get_settings(aWidget);
--
- aFontStyle->style = NS_FONT_STYLE_NORMAL;
-
-- gchar *fontname;
-- g_object_get(settings, "gtk-font-name", &fontname, nullptr);
--
-+ // As in
-+ // https://git.gnome.org/browse/gtk+/tree/gtk/gtkwidget.c?h=3.22.19#n10333
- PangoFontDescription *desc;
-- desc = pango_font_description_from_string(fontname);
-+ gtk_style_context_get(aStyle, gtk_style_context_get_state(aStyle),
-+ "font", &desc, nullptr);
-
- aFontStyle->systemFont = true;
-
-- g_free(fontname);
--
- NS_NAMED_LITERAL_STRING(quote, "\"");
- NS_ConvertUTF8toUTF16 family(pango_font_description_get_family(desc));
- *aFontName = quote + family + quote;
-@@ -953,96 +751,28 @@ GetSystemFontInfo(GtkWidget *aWidget,
- pango_font_description_free(desc);
- }
-
--static void
--GetSystemFontInfo(LookAndFeel::FontID aID,
-- nsString *aFontName,
-- gfxFontStyle *aFontStyle)
--{
-- if (aID == LookAndFeel::eFont_Widget) {
-- GtkWidget *label = gtk_label_new("M");
-- GtkWidget *parent = gtk_fixed_new();
-- GtkWidget *window = gtk_window_new(GTK_WINDOW_POPUP);
--
-- gtk_container_add(GTK_CONTAINER(parent), label);
-- gtk_container_add(GTK_CONTAINER(window), parent);
--
-- gtk_widget_ensure_style(label);
-- GetSystemFontInfo(label, aFontName, aFontStyle);
-- gtk_widget_destroy(window); // no unref, windows are different
--
-- } else if (aID == LookAndFeel::eFont_Button) {
-- GtkWidget *label = gtk_label_new("M");
-- GtkWidget *parent = gtk_fixed_new();
-- GtkWidget *button = gtk_button_new();
-- GtkWidget *window = gtk_window_new(GTK_WINDOW_POPUP);
--
-- gtk_container_add(GTK_CONTAINER(button), label);
-- gtk_container_add(GTK_CONTAINER(parent), button);
-- gtk_container_add(GTK_CONTAINER(window), parent);
--
-- gtk_widget_ensure_style(label);
-- GetSystemFontInfo(label, aFontName, aFontStyle);
-- gtk_widget_destroy(window); // no unref, windows are different
--
-- } else if (aID == LookAndFeel::eFont_Field) {
-- GtkWidget *entry = gtk_entry_new();
-- GtkWidget *parent = gtk_fixed_new();
-- GtkWidget *window = gtk_window_new(GTK_WINDOW_POPUP);
--
-- gtk_container_add(GTK_CONTAINER(parent), entry);
-- gtk_container_add(GTK_CONTAINER(window), parent);
--
-- gtk_widget_ensure_style(entry);
-- GetSystemFontInfo(entry, aFontName, aFontStyle);
-- gtk_widget_destroy(window); // no unref, windows are different
--
-- } else {
-- MOZ_ASSERT(aID == LookAndFeel::eFont_Menu, "unexpected font ID");
-- GtkWidget *accel_label = gtk_accel_label_new("M");
-- GtkWidget *menuitem = gtk_menu_item_new();
-- GtkWidget *menu = gtk_menu_new();
-- g_object_ref_sink(menu);
--
-- gtk_container_add(GTK_CONTAINER(menuitem), accel_label);
-- gtk_menu_shell_append((GtkMenuShell *)GTK_MENU(menu), menuitem);
--
-- gtk_widget_ensure_style(accel_label);
-- GetSystemFontInfo(accel_label, aFontName, aFontStyle);
-- g_object_unref(menu);
-- }
--}
--
- bool
- nsLookAndFeel::GetFontImpl(FontID aID, nsString& aFontName,
- gfxFontStyle& aFontStyle,
- float aDevPixPerCSSPixel)
- {
-- nsString *cachedFontName = nullptr;
-- gfxFontStyle *cachedFontStyle = nullptr;
-- bool *isCached = nullptr;
--
- switch (aID) {
- case eFont_Menu: // css2
- case eFont_PullDownMenu: // css3
-- cachedFontName = &mMenuFontName;
-- cachedFontStyle = &mMenuFontStyle;
-- isCached = &mMenuFontCached;
-- aID = eFont_Menu;
-- break;
-+ aFontName = mMenuFontName;
-+ aFontStyle = mMenuFontStyle;
-+ return true;
-
- case eFont_Field: // css3
- case eFont_List: // css3
-- cachedFontName = &mFieldFontName;
-- cachedFontStyle = &mFieldFontStyle;
-- isCached = &mFieldFontCached;
-- aID = eFont_Field;
-- break;
-+ aFontName = mFieldFontName;
-+ aFontStyle = mFieldFontStyle;
-+ return true;
-
- case eFont_Button: // css3
-- cachedFontName = &mButtonFontName;
-- cachedFontStyle = &mButtonFontStyle;
-- isCached = &mButtonFontCached;
-- break;
-+ aFontName = mButtonFontName;
-+ aFontStyle = mButtonFontStyle;
-+ return true;
-
- case eFont_Caption: // css2
- case eFont_Icon: // css2
-@@ -1057,21 +787,11 @@ nsLookAndFeel::GetFontImpl(FontID aID, nsString& aFontName,
- case eFont_Dialog: // css3
- case eFont_Tooltips: // moz
- case eFont_Widget: // moz
-- cachedFontName = &mDefaultFontName;
-- cachedFontStyle = &mDefaultFontStyle;
-- isCached = &mDefaultFontCached;
-- aID = eFont_Widget;
-- break;
-- }
--
-- if (!*isCached) {
-- GetSystemFontInfo(aID, cachedFontName, cachedFontStyle);
-- *isCached = true;
-+ default:
-+ aFontName = mDefaultFontName;
-+ aFontStyle = mDefaultFontStyle;
-+ return true;
- }
--
-- aFontName = *cachedFontName;
-- aFontStyle = *cachedFontStyle;
-- return true;
- }
-
- void
-@@ -1087,70 +807,6 @@ nsLookAndFeel::EnsureInit()
- // gtk does non threadsafe refcounting
- MOZ_ASSERT(NS_IsMainThread());
-
--#if (MOZ_WIDGET_GTK == 2)
-- NS_ASSERTION(!mStyle, "already initialized");
-- // GtkInvisibles come with a refcount that is not floating
-- // (since their initialization code calls g_object_ref_sink) and
-- // their destroy code releases that reference (which means they
-- // have to be explicitly destroyed, since calling unref enough
-- // to cause destruction would lead to *another* unref).
-- // However, this combination means that it's actually still ok
-- // to use the normal pattern, which is to g_object_ref_sink
-- // after construction, and then destroy *and* unref when we're
-- // done. (Though we could skip the g_object_ref_sink and the
-- // corresponding g_object_unref, but that's particular to
-- // GtkInvisibles and GtkWindows.)
-- GtkWidget *widget = gtk_invisible_new();
-- g_object_ref_sink(widget); // effectively g_object_ref (see above)
--
-- gtk_widget_ensure_style(widget);
-- mStyle = gtk_style_copy(gtk_widget_get_style(widget));
--
-- gtk_widget_destroy(widget);
-- g_object_unref(widget);
--
-- // tooltip foreground and background
-- GtkStyle *style = gtk_rc_get_style_by_paths(gtk_settings_get_default(),
-- "gtk-tooltips", "GtkWindow",
-- GTK_TYPE_WINDOW);
-- if (style) {
-- sInfoBackground = GDK_COLOR_TO_NS_RGB(style->bg[GTK_STATE_NORMAL]);
-- sInfoText = GDK_COLOR_TO_NS_RGB(style->fg[GTK_STATE_NORMAL]);
-- }
--
-- // menu foreground & menu background
-- GtkWidget *accel_label = gtk_accel_label_new("M");
-- GtkWidget *menuitem = gtk_menu_item_new();
-- GtkWidget *menu = gtk_menu_new();
--
-- g_object_ref_sink(menu);
--
-- gtk_container_add(GTK_CONTAINER(menuitem), accel_label);
-- gtk_menu_shell_append(GTK_MENU_SHELL(menu), menuitem);
--
-- gtk_widget_set_style(accel_label, nullptr);
-- gtk_widget_set_style(menu, nullptr);
-- gtk_widget_realize(menu);
-- gtk_widget_realize(accel_label);
--
-- style = gtk_widget_get_style(accel_label);
-- if (style) {
-- sMenuText = GDK_COLOR_TO_NS_RGB(style->fg[GTK_STATE_NORMAL]);
-- }
--
-- style = gtk_widget_get_style(menu);
-- if (style) {
-- sMenuBackground = GDK_COLOR_TO_NS_RGB(style->bg[GTK_STATE_NORMAL]);
-- }
--
-- style = gtk_widget_get_style(menuitem);
-- if (style) {
-- sMenuHover = GDK_COLOR_TO_NS_RGB(style->bg[GTK_STATE_PRELIGHT]);
-- sMenuHoverText = GDK_COLOR_TO_NS_RGB(style->fg[GTK_STATE_PRELIGHT]);
-- }
--
-- g_object_unref(menu);
--#else
- GdkRGBA color;
- GtkStyleContext *style;
-
-@@ -1195,6 +851,12 @@ nsLookAndFeel::EnsureInit()
- }
- }
-
-+ // The label is not added to a parent widget, but shared for constructing
-+ // different style contexts. The node hierarchy is constructed only on
-+ // the label style context.
-+ GtkWidget *labelWidget = gtk_label_new("M");
-+ g_object_ref_sink(labelWidget);
-+
- // Scrollbar colors
- style = ClaimStyleContext(MOZ_GTK_SCROLLBAR_TROUGH_VERTICAL);
- gtk_style_context_get_background_color(style, GTK_STATE_FLAG_NORMAL, &color);
-@@ -1208,6 +870,13 @@ nsLookAndFeel::EnsureInit()
- gtk_style_context_get_color(style, GTK_STATE_FLAG_NORMAL, &color);
- sMozWindowText = GDK_RGBA_TO_NS_RGBA(color);
- ReleaseStyleContext(style);
-+ style = ClaimStyleContext(MOZ_GTK_WINDOW_CONTAINER);
-+ {
-+ GtkStyleContext* labelStyle = CreateStyleForWidget(labelWidget, style);
-+ GetSystemFontInfo(labelStyle, &mDefaultFontName, &mDefaultFontStyle);
-+ g_object_unref(labelStyle);
-+ }
-+ ReleaseStyleContext(style);
-
- // tooltip foreground and background
- style = ClaimStyleContext(MOZ_GTK_TOOLTIP);
-@@ -1224,6 +893,9 @@ nsLookAndFeel::EnsureInit()
- {
- GtkStyleContext* accelStyle =
- CreateStyleForWidget(gtk_accel_label_new("M"), style);
-+
-+ GetSystemFontInfo(accelStyle, &mMenuFontName, &mMenuFontStyle);
-+
- gtk_style_context_get_color(accelStyle, GTK_STATE_FLAG_NORMAL, &color);
- sMenuText = GDK_RGBA_TO_NS_RGBA(color);
- gtk_style_context_get_color(accelStyle, GTK_STATE_FLAG_INSENSITIVE, &color);
-@@ -1243,17 +915,8 @@ nsLookAndFeel::EnsureInit()
- gtk_style_context_get_color(style, GTK_STATE_FLAG_PRELIGHT, &color);
- sMenuHoverText = GDK_RGBA_TO_NS_RGBA(color);
- ReleaseStyleContext(style);
--#endif
-
-- // button styles
- GtkWidget *parent = gtk_fixed_new();
-- GtkWidget *button = gtk_button_new();
-- GtkWidget *label = gtk_label_new("M");
--#if (MOZ_WIDGET_GTK == 2)
-- GtkWidget *combobox = gtk_combo_box_new();
-- GtkWidget *comboboxLabel = gtk_label_new("M");
-- gtk_container_add(GTK_CONTAINER(combobox), comboboxLabel);
--#endif
- GtkWidget *window = gtk_window_new(GTK_WINDOW_POPUP);
- GtkWidget *treeView = gtk_tree_view_new();
- GtkWidget *linkButton = gtk_link_button_new("http://example.com/");
-@@ -1262,94 +925,14 @@ nsLookAndFeel::EnsureInit()
- GtkWidget *entry = gtk_entry_new();
- GtkWidget *textView = gtk_text_view_new();
-
-- gtk_container_add(GTK_CONTAINER(button), label);
-- gtk_container_add(GTK_CONTAINER(parent), button);
- gtk_container_add(GTK_CONTAINER(parent), treeView);
- gtk_container_add(GTK_CONTAINER(parent), linkButton);
--#if (MOZ_WIDGET_GTK == 2)
-- gtk_container_add(GTK_CONTAINER(parent), combobox);
--#endif
- gtk_container_add(GTK_CONTAINER(parent), menuBar);
- gtk_menu_shell_append(GTK_MENU_SHELL(menuBar), menuBarItem);
- gtk_container_add(GTK_CONTAINER(window), parent);
- gtk_container_add(GTK_CONTAINER(parent), entry);
- gtk_container_add(GTK_CONTAINER(parent), textView);
-
--#if (MOZ_WIDGET_GTK == 2)
-- gtk_widget_set_style(button, nullptr);
-- gtk_widget_set_style(label, nullptr);
-- gtk_widget_set_style(treeView, nullptr);
-- gtk_widget_set_style(linkButton, nullptr);
-- gtk_widget_set_style(combobox, nullptr);
-- gtk_widget_set_style(comboboxLabel, nullptr);
-- gtk_widget_set_style(menuBar, nullptr);
-- gtk_widget_set_style(entry, nullptr);
--
-- gtk_widget_realize(button);
-- gtk_widget_realize(label);
-- gtk_widget_realize(treeView);
-- gtk_widget_realize(linkButton);
-- gtk_widget_realize(combobox);
-- gtk_widget_realize(comboboxLabel);
-- gtk_widget_realize(menuBar);
-- gtk_widget_realize(entry);
--
-- style = gtk_widget_get_style(label);
-- if (style) {
-- sButtonText = GDK_COLOR_TO_NS_RGB(style->fg[GTK_STATE_NORMAL]);
-- }
--
-- style = gtk_widget_get_style(comboboxLabel);
-- if (style) {
-- sComboBoxText = GDK_COLOR_TO_NS_RGB(style->fg[GTK_STATE_NORMAL]);
-- }
-- style = gtk_widget_get_style(combobox);
-- if (style) {
-- sComboBoxBackground = GDK_COLOR_TO_NS_RGB(style->bg[GTK_STATE_NORMAL]);
-- }
--
-- style = gtk_widget_get_style(menuBar);
-- if (style) {
-- sMenuBarText = GDK_COLOR_TO_NS_RGB(style->fg[GTK_STATE_NORMAL]);
-- sMenuBarHoverText = GDK_COLOR_TO_NS_RGB(style->fg[GTK_STATE_SELECTED]);
-- }
--
-- // GTK's guide to fancy odd row background colors:
-- // 1) Check if a theme explicitly defines an odd row color
-- // 2) If not, check if it defines an even row color, and darken it
-- // slightly by a hardcoded value (gtkstyle.c)
-- // 3) If neither are defined, take the base background color and
-- // darken that by a hardcoded value
-- colorValuePtr = nullptr;
-- gtk_widget_style_get(treeView,
-- "odd-row-color", &colorValuePtr,
-- nullptr);
--
-- if (colorValuePtr) {
-- colorValue = *colorValuePtr;
-- } else {
-- gtk_widget_style_get(treeView,
-- "even-row-color", &colorValuePtr,
-- nullptr);
-- if (colorValuePtr)
-- darken_gdk_color(colorValuePtr, &colorValue);
-- else
-- darken_gdk_color(&treeView->style->base[GTK_STATE_NORMAL], &colorValue);
-- }
--
-- sOddCellBackground = GDK_COLOR_TO_NS_RGB(colorValue);
-- if (colorValuePtr)
-- gdk_color_free(colorValuePtr);
--
-- style = gtk_widget_get_style(button);
-- if (style) {
-- sButtonBackground = GDK_COLOR_TO_NS_RGB(style->bg[GTK_STATE_NORMAL]);
-- sFrameOuterLightBorder =
-- GDK_COLOR_TO_NS_RGB(style->light[GTK_STATE_NORMAL]);
-- sFrameInnerDarkBorder =
-- GDK_COLOR_TO_NS_RGB(style->dark[GTK_STATE_NORMAL]);
-- }
--#else
- // Text colors
- GdkRGBA bgColor;
- // If the text window background is translucent, then the background of
-@@ -1381,8 +964,10 @@ nsLookAndFeel::EnsureInit()
- // Button text color
- style = ClaimStyleContext(MOZ_GTK_BUTTON);
- {
-- GtkStyleContext* labelStyle =
-- CreateStyleForWidget(gtk_label_new("M"), style);
-+ GtkStyleContext* labelStyle = CreateStyleForWidget(labelWidget, style);
-+
-+ GetSystemFontInfo(labelStyle, &mButtonFontName, &mButtonFontStyle);
-+
- gtk_style_context_get_color(labelStyle, GTK_STATE_FLAG_NORMAL, &color);
- sButtonText = GDK_RGBA_TO_NS_RGBA(color);
- gtk_style_context_get_color(labelStyle, GTK_STATE_FLAG_PRELIGHT, &color);
-@@ -1446,7 +1031,6 @@ nsLookAndFeel::EnsureInit()
- gtk_style_context_add_class(style, GTK_STYLE_CLASS_INFO);
- gtk_style_context_get_color(style, GTK_STATE_FLAG_NORMAL, &color);
- sInfoBarText = GDK_RGBA_TO_NS_RGBA(color);
--#endif
- // Some themes have a unified menu bar, and support window dragging on it
- gboolean supports_menubar_drag = FALSE;
- GParamSpec *param_spec =
-@@ -1493,7 +1074,11 @@ nsLookAndFeel::EnsureInit()
- "cursor-aspect-ratio", &sCaretRatio,
- nullptr);
-
-+ GetSystemFontInfo(gtk_widget_get_style_context(entry),
-+ &mFieldFontName, &mFieldFontStyle);
-+
- gtk_widget_destroy(window);
-+ g_object_unref(labelWidget);
- }
-
- // virtual
-@@ -1515,11 +1100,6 @@ nsLookAndFeel::RefreshImpl()
- mFieldFontCached = false;
- mMenuFontCached = false;
-
--#if (MOZ_WIDGET_GTK == 2)
-- g_object_unref(mStyle);
-- mStyle = nullptr;
--#endif
--
- mInitialized = false;
- }
-
-diff --git widget/gtk/nsLookAndFeel.h widget/gtk/nsLookAndFeel.h
-index 9a4015e95415..38cd51c056d6 100644
---- widget/gtk/nsLookAndFeel.h
-+++ widget/gtk/nsLookAndFeel.h
-@@ -33,9 +33,6 @@ public:
- virtual bool GetEchoPasswordImpl();
-
- protected:
--#if (MOZ_WIDGET_GTK == 2)
-- struct _GtkStyle *mStyle;
--#endif
-
- // Cached fonts
- bool mDefaultFontCached;
-@@ -63,7 +60,6 @@ protected:
- nscolor sMenuHoverText;
- nscolor sButtonText;
- nscolor sButtonHoverText;
-- nscolor sButtonBackground;
- nscolor sFrameOuterLightBorder;
- nscolor sFrameInnerDarkBorder;
- nscolor sOddCellBackground;
-@@ -77,9 +73,7 @@ protected:
- nscolor sTextSelectedText;
- nscolor sTextSelectedBackground;
- nscolor sMozScrollbar;
--#if (MOZ_WIDGET_GTK == 3)
- nscolor sInfoBarText;
--#endif
- char16_t sInvisibleCharacter;
- float sCaretRatio;
- bool sMenuSupportsDrag;
diff --git a/www/firefox/files/patch-bug1386887 b/www/firefox/files/patch-bug1386887
deleted file mode 100644
index 7421a8d84012..000000000000
--- a/www/firefox/files/patch-bug1386887
+++ /dev/null
@@ -1,89 +0,0 @@
-commit efbe3a9af876
-Author: Manish Goregaokar <manishearth@gmail.com>
-Date: Wed Aug 2 11:24:35 2017 -0700
-
- Bug 1386887 - Clean up FFI lifetimes to work on nightly; r=emilio
-
- MozReview-Commit-ID: 5WAIVd6p2du
----
- layout/style/ServoBindingList.h | 4 ++--
- layout/style/ServoBindingTypes.h | 2 ++
- layout/style/ServoBindings.h | 4 ++--
- layout/style/ServoBindings.toml | 4 +++-
- 4 files changed, 9 insertions(+), 5 deletions(-)
-
-diff --git layout/style/ServoBindingList.h layout/style/ServoBindingList.h
-index 6c669ebb3d3e..87ade14ea4de 100644
---- layout/style/ServoBindingList.h
-+++ layout/style/ServoBindingList.h
-@@ -379,10 +379,10 @@ SERVO_BINDING_FUNC(Servo_DeclarationBlock_HasCSSWideKeyword, bool,
- nsCSSPropertyID property)
- // Compose animation value for a given property.
- // |base_values| is nsRefPtrHashtable<nsUint32HashKey, RawServoAnimationValue>.
--// We use void* to avoid exposing nsRefPtrHashtable in FFI.
-+// We use RawServoAnimationValueTableBorrowed to avoid exposing nsRefPtrHashtable in FFI.
- SERVO_BINDING_FUNC(Servo_AnimationCompose, void,
- RawServoAnimationValueMapBorrowedMut animation_values,
-- void* base_values,
-+ RawServoAnimationValueTableBorrowed base_values,
- nsCSSPropertyID property,
- RawGeckoAnimationPropertySegmentBorrowed animation_segment,
- RawGeckoAnimationPropertySegmentBorrowed last_segment,
-diff --git layout/style/ServoBindingTypes.h layout/style/ServoBindingTypes.h
-index aaf4fc27e1b9..69be15ee9f51 100644
---- layout/style/ServoBindingTypes.h
-+++ layout/style/ServoBindingTypes.h
-@@ -54,6 +54,8 @@ class nsXBLBinding;
- using mozilla::dom::StyleChildrenIterator;
- using mozilla::ServoElementSnapshot;
-
-+typedef void* RawServoAnimationValueTableBorrowed;
-+
- typedef nsINode RawGeckoNode;
- typedef mozilla::dom::Element RawGeckoElement;
- typedef nsIDocument RawGeckoDocument;
-diff --git layout/style/ServoBindings.h layout/style/ServoBindings.h
-index 493ca63f932b..c6ced6d1fedb 100644
---- layout/style/ServoBindings.h
-+++ layout/style/ServoBindings.h
-@@ -268,9 +268,9 @@ double Gecko_GetPositionInSegment(
- // Get servo's AnimationValue for |aProperty| from the cached base style
- // |aBaseStyles|.
- // |aBaseStyles| is nsRefPtrHashtable<nsUint32HashKey, RawServoAnimationValue>.
--// We use void* to avoid exposing nsRefPtrHashtable in FFI.
-+// We use RawServoAnimationValueTableBorrowed to avoid exposing nsRefPtrHashtable in FFI.
- RawServoAnimationValueBorrowedOrNull Gecko_AnimationGetBaseStyle(
-- void* aBaseStyles,
-+ RawServoAnimationValueTableBorrowed aBaseStyles,
- nsCSSPropertyID aProperty);
- void Gecko_StyleTransition_SetUnsupportedProperty(
- mozilla::StyleTransition* aTransition,
-diff --git layout/style/ServoBindings.toml layout/style/ServoBindings.toml
-index 11e372541235..3c3902beea80 100644
---- layout/style/ServoBindings.toml
-+++ layout/style/ServoBindings.toml
-@@ -357,6 +357,7 @@ raw-lines = [
- "pub type ServoStyleContextBorrowed<'a> = &'a ::properties::ComputedValues;",
- "pub type ServoStyleContextBorrowedOrNull<'a> = Option<&'a ::properties::ComputedValues>;",
- "pub type ServoComputedDataBorrowed<'a> = &'a ServoComputedData;",
-+ "pub type RawServoAnimationValueTableBorrowed<'a> = &'a ();"
- ]
- whitelist-functions = ["Servo_.*", "Gecko_.*"]
- structs-types = [
-@@ -389,7 +390,7 @@ structs-types = [
- "RawGeckoPresContext",
- "RawGeckoPresContextOwned",
- "RawGeckoStyleAnimationList",
-- "RawGeckoStyleChildrenIteratorBorrowedMut",
-+ "RawGeckoStyleChildrenIterator",
- "RawGeckoServoStyleRuleList",
- "RawGeckoURLExtraData",
- "RawGeckoXBLBinding",
-@@ -526,6 +527,7 @@ servo-borrow-types = [
- "RawGeckoFontFaceRuleList",
- "RawGeckoServoStyleRuleList",
- "RawGeckoServoAnimationValueList",
-+ "RawGeckoStyleChildrenIterator",
- ]
- fixups = [
- # hack for gecko-owned string
diff --git a/www/firefox/files/patch-bug1386957 b/www/firefox/files/patch-bug1386957
deleted file mode 100644
index 34b38c5c1298..000000000000
--- a/www/firefox/files/patch-bug1386957
+++ /dev/null
@@ -1,14 +0,0 @@
-https://github.com/kinetiknz/cubeb/commit/16f9ccc064f2
-
---- media/libcubeb/src/cubeb_jack.cpp.orig 2017-07-07 05:37:16 UTC
-+++ media/libcubeb/src/cubeb_jack.cpp
-@@ -8,7 +8,9 @@
- */
- #define _DEFAULT_SOURCE
- #define _BSD_SOURCE
-+#ifndef __FreeBSD__
- #define _POSIX_SOURCE
-+#endif
- #include <dlfcn.h>
- #include <stdio.h>
- #include <string.h>
diff --git a/www/firefox/files/patch-bug1387799 b/www/firefox/files/patch-bug1387799
deleted file mode 100644
index e79b52603427..000000000000
--- a/www/firefox/files/patch-bug1387799
+++ /dev/null
@@ -1,49 +0,0 @@
-commit e1c252eab1f4
-Author: Milan Sreckovic <milan@mozilla.com>
-Date: Mon Oct 23 16:22:47 2017 -0400
-
- Bug 1387799 - Keep an extra reference. r=jrmuizel, a=ritu
-
- --HG--
- extra : source : 8199078921c6b4c0ee4c984100d33750dfe8e144
----
- gfx/layers/ipc/CompositorBridgeChild.cpp | 11 ++++++++---
- 1 file changed, 8 insertions(+), 3 deletions(-)
-
-diff --git gfx/layers/ipc/CompositorBridgeChild.cpp gfx/layers/ipc/CompositorBridgeChild.cpp
-index 9419f4b2da36..55fd9c10871b 100644
---- gfx/layers/ipc/CompositorBridgeChild.cpp
-+++ gfx/layers/ipc/CompositorBridgeChild.cpp
-@@ -523,10 +523,14 @@ CompositorBridgeChild::RecvHideAllPlugins(const uintptr_t& aParentWidget)
- }
-
- mozilla::ipc::IPCResult
--CompositorBridgeChild::RecvDidComposite(const uint64_t& aId, const uint64_t& aTransactionId,
-+CompositorBridgeChild::RecvDidComposite(const uint64_t& aId,
-+ const uint64_t& aTransactionId,
- const TimeStamp& aCompositeStart,
- const TimeStamp& aCompositeEnd)
- {
-+ // Hold a reference to keep texture pools alive. See bug 1387799
-+ AutoTArray<RefPtr<TextureClientPool>,2> texturePools = mTexturePools;
-+
- if (mLayerManager) {
- MOZ_ASSERT(aId == 0);
- MOZ_ASSERT(mLayerManager->GetBackendType() == LayersBackend::LAYERS_CLIENT ||
-@@ -541,13 +545,14 @@ CompositorBridgeChild::RecvDidComposite(const uint64_t& aId, const uint64_t& aTr
- }
- }
-
-- for (size_t i = 0; i < mTexturePools.Length(); i++) {
-- mTexturePools[i]->ReturnDeferredClients();
-+ for (size_t i = 0; i < texturePools.Length(); i++) {
-+ texturePools[i]->ReturnDeferredClients();
- }
-
- return IPC_OK();
- }
-
-+
- void
- CompositorBridgeChild::ActorDestroy(ActorDestroyReason aWhy)
- {
diff --git a/www/firefox/files/patch-bug1387811 b/www/firefox/files/patch-bug1387811
deleted file mode 100644
index 9198b313f899..000000000000
--- a/www/firefox/files/patch-bug1387811
+++ /dev/null
@@ -1,42 +0,0 @@
-commit a1341ccf6d63
-Author: Christoph Kerschbaumer <ckerschb@christophkerschbaumer.com>
-Date: Sun Aug 6 11:37:09 2017 +0200
-
- Bug 1387811 - Follow up for Test within Bug 1381761: CSP JSON is never null, hence it's better to check actual contents of JSON for testing. r=dveditz
----
- dom/security/test/csp/file_data_csp_inheritance.html | 6 ++++--
- dom/security/test/csp/test_data_csp_inheritance.html | 4 +++-
- 2 files changed, 7 insertions(+), 3 deletions(-)
-
-diff --git dom/security/test/csp/file_data_csp_inheritance.html dom/security/test/csp/file_data_csp_inheritance.html
-index 299c30255aa6..cbb4865343db 100644
---- dom/security/test/csp/file_data_csp_inheritance.html
-+++ dom/security/test/csp/file_data_csp_inheritance.html
-@@ -13,8 +13,10 @@
- var frame = document.getElementById("dataFrame");
- var principal = SpecialPowers.wrap(frame.contentDocument).nodePrincipal;
- var cspJSON = principal.cspJSON;
-- var result = principal.cspJSON ? "dataInheritsCSP" : "dataDoesNotInheritCSP";
-- window.parent.postMessage({result}, "*");
-+ var cspOBJ = JSON.parse(principal.cspJSON);
-+ // make sure we got >>one<< policy
-+ var policies = cspOBJ["csp-policies"];
-+ window.parent.postMessage({result: policies.length}, "*");
- </script>
-
- </body>
-diff --git dom/security/test/csp/test_data_csp_inheritance.html dom/security/test/csp/test_data_csp_inheritance.html
-index 3afc4f7c02bc..bde2f5617e65 100644
---- dom/security/test/csp/test_data_csp_inheritance.html
-+++ dom/security/test/csp/test_data_csp_inheritance.html
-@@ -22,7 +22,9 @@ SimpleTest.waitForExplicitFinish();
- window.addEventListener("message", receiveMessage);
- function receiveMessage(event) {
- window.removeEventListener("message", receiveMessage);
-- is(event.data.result, "dataInheritsCSP",
-+ // toplevel CSP should apply to data: URI iframe hence resulting
-+ // in 1 applied policy.
-+ is(event.data.result, 1,
- "data: URI iframe inherits CSP from including context");
- SimpleTest.finish();
- }
diff --git a/www/firefox/files/patch-bug1387845 b/www/firefox/files/patch-bug1387845
deleted file mode 100644
index c8a72db0b31e..000000000000
--- a/www/firefox/files/patch-bug1387845
+++ /dev/null
@@ -1,38 +0,0 @@
-commit 8687f49efa88
-Author: sotaro <sotaro.ikeda.g@gmail.com>
-Date: Wed Aug 23 13:49:29 2017 +0900
-
- Bug 1387845 - Add more NS_BUILD_REFCNT_LOGGING in AtomicRefCountedWithFinalize r=nical
----
- gfx/layers/AtomicRefCountedWithFinalize.h | 10 ++++++++--
- 1 file changed, 8 insertions(+), 2 deletions(-)
-
-diff --git gfx/layers/AtomicRefCountedWithFinalize.h gfx/layers/AtomicRefCountedWithFinalize.h
-index 37f0a9f592a1..9941ccb13f2d 100644
---- gfx/layers/AtomicRefCountedWithFinalize.h
-+++ gfx/layers/AtomicRefCountedWithFinalize.h
-@@ -101,8 +101,12 @@ public:
- private:
- void AddRef() {
- MOZ_ASSERT(mRefCount >= 0, "AddRef() during/after Finalize()/dtor.");
-- mRefCount++;
-- NS_LOG_ADDREF(this, mRefCount, mName, sizeof(*this));
-+#ifdef NS_BUILD_REFCNT_LOGGING
-+ int currCount = ++mRefCount;
-+ NS_LOG_ADDREF(this, currCount, mName, sizeof(*this));
-+#else
-+ ++mRefCount;
-+#endif
- }
-
- void Release() {
-@@ -118,7 +122,9 @@ private:
- ++mRefCount;
- return;
- }
-+#ifdef NS_BUILD_REFCNT_LOGGING
- NS_LOG_RELEASE(this, currCount, mName);
-+#endif
-
- if (0 == currCount) {
- mRefCount = detail::DEAD;
diff --git a/www/firefox/files/patch-bug1393283 b/www/firefox/files/patch-bug1393283
deleted file mode 100644
index 0a4b9327ea2b..000000000000
--- a/www/firefox/files/patch-bug1393283
+++ /dev/null
@@ -1,144 +0,0 @@
-commit d20c7d929c84
-Author: Ethan <ettseng@mozilla.com>
-Date: Fri Sep 1 17:29:44 2017 +0800
-
- Bug 1393283 - Use the last ESR version as the spoofed Firefox version. r=tihuang, r=mcmanus
----
- .../test/browser/browser_navigator.js | 2 +-
- netwerk/protocol/http/nsHttpHandler.cpp | 16 +++----
- .../resistfingerprinting/nsRFPService.cpp | 56 ++++++++++++++++++++++
- .../components/resistfingerprinting/nsRFPService.h | 3 ++
- 4 files changed, 66 insertions(+), 11 deletions(-)
-
-diff --git browser/components/resistfingerprinting/test/browser/browser_navigator.js browser/components/resistfingerprinting/test/browser/browser_navigator.js
-index 25c393d8bb2a..9f52e34a9451 100644
---- browser/components/resistfingerprinting/test/browser/browser_navigator.js
-+++ browser/components/resistfingerprinting/test/browser/browser_navigator.js
-@@ -91,7 +91,7 @@ add_task(async function setup() {
-
- let appInfo = Cc["@mozilla.org/xre/app-info;1"].getService(Ci.nsIXULAppInfo);
- let appVersion = parseInt(appInfo.version);
-- let spoofedVersion = appVersion - (appVersion % 10);
-+ let spoofedVersion = appVersion - ((appVersion - 3) % 7);
- spoofedUserAgent = `Mozilla/5.0 (${SPOOFED_OSCPU}; rv:${spoofedVersion}.0) Gecko/20100101 Firefox/${spoofedVersion}.0`;
- });
-
-diff --git netwerk/protocol/http/nsHttpHandler.cpp netwerk/protocol/http/nsHttpHandler.cpp
-index 31d0f8832732..b957d835b52f 100644
---- netwerk/protocol/http/nsHttpHandler.cpp
-+++ netwerk/protocol/http/nsHttpHandler.cpp
-@@ -461,16 +461,12 @@ nsHttpHandler::Init()
- mAppVersion.AssignLiteral(MOZ_APP_UA_VERSION);
- }
-
-- // Generating the spoofed userAgent for fingerprinting resistance.
-- // The browser version will be rounded down to a multiple of 10.
-- // By doing so, the anonymity group will cover more versions instead of one
-- // version.
-- uint32_t spoofedVersion = mAppVersion.ToInteger(&rv);
-- if (NS_SUCCEEDED(rv)) {
-- spoofedVersion = spoofedVersion - (spoofedVersion % 10);
-- mSpoofedUserAgent.Assign(nsPrintfCString(
-- "Mozilla/5.0 (%s; rv:%d.0) Gecko/%s Firefox/%d.0",
-- SPOOFED_OSCPU, spoofedVersion, LEGACY_BUILD_ID, spoofedVersion));
-+ // Generating the spoofed User Agent for fingerprinting resistance.
-+ rv = nsRFPService::GetSpoofedUserAgent(mSpoofedUserAgent);
-+ if (NS_FAILED(rv)) {
-+ // Empty mSpoofedUserAgent to make sure the unsuccessful spoofed UA string
-+ // will not be used anywhere.
-+ mSpoofedUserAgent.Truncate();
- }
-
- mSessionStartTime = NowInSeconds();
-diff --git toolkit/components/resistfingerprinting/nsRFPService.cpp toolkit/components/resistfingerprinting/nsRFPService.cpp
-index 94554200c3b8..96a2940c04a0 100644
---- toolkit/components/resistfingerprinting/nsRFPService.cpp
-+++ toolkit/components/resistfingerprinting/nsRFPService.cpp
-@@ -18,10 +18,13 @@
- #include "nsServiceManagerUtils.h"
- #include "nsString.h"
- #include "nsXULAppAPI.h"
-+#include "nsPrintfCString.h"
-
- #include "nsIObserverService.h"
- #include "nsIPrefBranch.h"
- #include "nsIPrefService.h"
-+#include "nsIXULAppInfo.h"
-+#include "nsIXULRuntime.h"
- #include "nsJSUtils.h"
-
- #include "prenv.h"
-@@ -162,6 +165,59 @@ nsRFPService::GetSpoofedPresentedFrames(double aTime, uint32_t aWidth, uint32_t
- return NSToIntFloor(time * sVideoFramesPerSec * ((100 - boundedDroppedRatio) / 100.0));
- }
-
-+/* static */
-+nsresult
-+nsRFPService::GetSpoofedUserAgent(nsACString &userAgent)
-+{
-+ // This function generates the spoofed value of User Agent.
-+ // We spoof the values of the platform and Firefox version, which could be
-+ // used as fingerprinting sources to identify individuals.
-+ // Reference of the format of User Agent:
-+ // https://developer.mozilla.org/en-US/docs/Web/API/NavigatorID/userAgent
-+ // https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/User-Agent
-+
-+ nsresult rv;
-+ nsCOMPtr<nsIXULAppInfo> appInfo =
-+ do_GetService("@mozilla.org/xre/app-info;1", &rv);
-+ NS_ENSURE_SUCCESS(rv, rv);
-+
-+ nsAutoCString appVersion;
-+ rv = appInfo->GetVersion(appVersion);
-+ NS_ENSURE_SUCCESS(rv, rv);
-+
-+ // The browser version will be spoofed as the last ESR version.
-+ // By doing so, the anonymity group will cover more versions instead of one
-+ // version.
-+ uint32_t firefoxVersion = appVersion.ToInteger(&rv);
-+ NS_ENSURE_SUCCESS(rv, rv);
-+
-+ // Starting from Firefox 10, Firefox ESR was released once every seven
-+ // Firefox releases, e.g. Firefox 10, 17, 24, 31, and so on.
-+ // We infer the last and closest ESR version based on this rule.
-+ nsCOMPtr<nsIXULRuntime> runtime =
-+ do_GetService("@mozilla.org/xre/runtime;1", &rv);
-+ NS_ENSURE_SUCCESS(rv, rv);
-+
-+ nsAutoCString updateChannel;
-+ rv = runtime->GetDefaultUpdateChannel(updateChannel);
-+ NS_ENSURE_SUCCESS(rv, rv);
-+
-+ // If we are running in Firefox ESR, determine whether the formula of ESR
-+ // version has changed. Once changed, we must update the formula in this
-+ // function.
-+ if (updateChannel.Equals("esr")) {
-+ MOZ_ASSERT(((firefoxVersion % 7) == 3),
-+ "Please udpate ESR version formula in nsRFPService.cpp");
-+ }
-+
-+ uint32_t spoofedVersion = firefoxVersion - ((firefoxVersion - 3) % 7);
-+ userAgent.Assign(nsPrintfCString(
-+ "Mozilla/5.0 (%s; rv:%d.0) Gecko/%s Firefox/%d.0",
-+ SPOOFED_OSCPU, spoofedVersion, LEGACY_BUILD_ID, spoofedVersion));
-+
-+ return rv;
-+}
-+
- nsresult
- nsRFPService::Init()
- {
-diff --git toolkit/components/resistfingerprinting/nsRFPService.h toolkit/components/resistfingerprinting/nsRFPService.h
-index cf1f688bb992..bad80383883b 100644
---- toolkit/components/resistfingerprinting/nsRFPService.h
-+++ toolkit/components/resistfingerprinting/nsRFPService.h
-@@ -49,6 +49,9 @@ public:
- static uint32_t GetSpoofedDroppedFrames(double aTime, uint32_t aWidth, uint32_t aHeight);
- static uint32_t GetSpoofedPresentedFrames(double aTime, uint32_t aWidth, uint32_t aHeight);
-
-+ // This method generates the spoofed value of User Agent.
-+ static nsresult GetSpoofedUserAgent(nsACString &userAgent);
-+
- private:
- nsresult Init();
-
diff --git a/www/firefox/files/patch-bug1394031 b/www/firefox/files/patch-bug1394031
deleted file mode 100644
index e9186ccd385c..000000000000
--- a/www/firefox/files/patch-bug1394031
+++ /dev/null
@@ -1,387 +0,0 @@
-commit e70d76485c22
-Author: Thomas Nguyen <tnguyen@mozilla.com>
-Date: Tue Sep 5 17:14:54 2017 +0800
-
- Bug 1394031 - Remove mCryptoHash members of nsUrlClassifierDBServiceWorker and ProtocolParser
-
- The usage of cryptoHash consists of a complete set of Init, Update, and Finish, there's
- no reason to keep it around
-
- MozReview-Commit-ID: 7bT9IsWEM5m
----
- toolkit/components/url-classifier/Classifier.cpp | 5 +---
- toolkit/components/url-classifier/Classifier.h | 2 --
- toolkit/components/url-classifier/Entries.h | 12 ++++++----
- .../components/url-classifier/ProtocolParser.cpp | 15 ++++--------
- toolkit/components/url-classifier/ProtocolParser.h | 4 ----
- .../url-classifier/nsUrlClassifierDBService.cpp | 8 -------
- .../url-classifier/nsUrlClassifierDBService.h | 3 ---
- .../url-classifier/tests/gtest/Common.cpp | 3 +--
- .../url-classifier/tests/gtest/TestCaching.cpp | 28 ++++++++--------------
- .../url-classifier/tests/gtest/TestClassifier.cpp | 3 +--
- .../tests/gtest/TestLookupCacheV4.cpp | 3 +--
- .../tests/unit/head_urlclassifier.js | 3 +++
- 12 files changed, 29 insertions(+), 60 deletions(-)
-
-diff --git toolkit/components/url-classifier/Classifier.cpp toolkit/components/url-classifier/Classifier.cpp
-index 68169925d2d0..404e31e2421e 100644
---- toolkit/components/url-classifier/Classifier.cpp
-+++ toolkit/components/url-classifier/Classifier.cpp
-@@ -257,9 +257,6 @@ Classifier::Open(nsIFile& aCacheDirectory)
- rv = CreateStoreDirectory();
- NS_ENSURE_SUCCESS(rv, rv);
-
-- mCryptoHash = do_CreateInstance(NS_CRYPTO_HASH_CONTRACTID, &rv);
-- NS_ENSURE_SUCCESS(rv, rv);
--
- // Build the list of know urlclassifier lists
- // XXX: Disk IO potentially on the main thread during startup
- RegenActiveTables();
-@@ -470,7 +467,7 @@ Classifier::Check(const nsACString& aSpec,
- // Now check each lookup fragment against the entries in the DB.
- for (uint32_t i = 0; i < fragments.Length(); i++) {
- Completion lookupHash;
-- lookupHash.FromPlaintext(fragments[i], mCryptoHash);
-+ lookupHash.FromPlaintext(fragments[i]);
-
- if (LOG_ENABLED()) {
- nsAutoCString checking;
-diff --git toolkit/components/url-classifier/Classifier.h toolkit/components/url-classifier/Classifier.h
-index 83cbcecf5ee8..e8bf890dc95a 100644
---- toolkit/components/url-classifier/Classifier.h
-+++ toolkit/components/url-classifier/Classifier.h
-@@ -13,7 +13,6 @@
- #include "nsCOMPtr.h"
- #include "nsString.h"
- #include "nsIFile.h"
--#include "nsICryptoHash.h"
- #include "nsDataHashtable.h"
-
- class nsIThread;
-@@ -207,7 +206,6 @@ private:
- nsCOMPtr<nsIFile> mBackupDirectory;
- nsCOMPtr<nsIFile> mUpdatingDirectory; // For update only.
- nsCOMPtr<nsIFile> mToDeleteDirectory;
-- nsCOMPtr<nsICryptoHash> mCryptoHash;
- nsTArray<LookupCache*> mLookupCaches; // For query only.
- nsTArray<nsCString> mActiveTablesCache;
- uint32_t mHashKey;
-diff --git toolkit/components/url-classifier/Entries.h toolkit/components/url-classifier/Entries.h
-index bb32204db0f3..d664b57f1d27 100644
---- toolkit/components/url-classifier/Entries.h
-+++ toolkit/components/url-classifier/Entries.h
-@@ -35,21 +35,25 @@ struct SafebrowsingHash
- typedef SafebrowsingHash<S, Comparator> self_type;
- uint8_t buf[S];
-
-- nsresult FromPlaintext(const nsACString& aPlainText, nsICryptoHash* aHash) {
-+ nsresult FromPlaintext(const nsACString& aPlainText) {
- // From the protocol doc:
- // Each entry in the chunk is composed
- // of the SHA 256 hash of a suffix/prefix expression.
-+ nsresult rv;
-+ nsCOMPtr<nsICryptoHash> hash =
-+ do_CreateInstance(NS_CRYPTO_HASH_CONTRACTID, &rv);
-+ NS_ENSURE_SUCCESS(rv, rv);
-
-- nsresult rv = aHash->Init(nsICryptoHash::SHA256);
-+ rv = hash->Init(nsICryptoHash::SHA256);
- NS_ENSURE_SUCCESS(rv, rv);
-
-- rv = aHash->Update
-+ rv = hash->Update
- (reinterpret_cast<const uint8_t*>(aPlainText.BeginReading()),
- aPlainText.Length());
- NS_ENSURE_SUCCESS(rv, rv);
-
- nsAutoCString hashed;
-- rv = aHash->Finish(false, hashed);
-+ rv = hash->Finish(false, hashed);
- NS_ENSURE_SUCCESS(rv, rv);
-
- NS_ASSERTION(hashed.Length() >= sHashSize,
-diff --git toolkit/components/url-classifier/ProtocolParser.cpp toolkit/components/url-classifier/ProtocolParser.cpp
-index 5f61c7bbcf6b..d4fce581e394 100644
---- toolkit/components/url-classifier/ProtocolParser.cpp
-+++ toolkit/components/url-classifier/ProtocolParser.cpp
-@@ -80,13 +80,6 @@ ProtocolParser::~ProtocolParser()
- CleanupUpdates();
- }
-
--nsresult
--ProtocolParser::Init(nsICryptoHash* aHasher)
--{
-- mCryptoHash = aHasher;
-- return NS_OK;
--}
--
- void
- ProtocolParser::CleanupUpdates()
- {
-@@ -404,7 +397,7 @@ ProtocolParserV2::ProcessPlaintextChunk(const nsACString& aChunk)
- if (mChunkState.type == CHUNK_ADD) {
- if (mChunkState.hashSize == COMPLETE_SIZE) {
- Completion hash;
-- hash.FromPlaintext(line, mCryptoHash);
-+ hash.FromPlaintext(line);
- nsresult rv = mTableUpdate->NewAddComplete(mChunkState.num, hash);
- if (NS_FAILED(rv)) {
- return rv;
-@@ -412,7 +405,7 @@ ProtocolParserV2::ProcessPlaintextChunk(const nsACString& aChunk)
- } else {
- NS_ASSERTION(mChunkState.hashSize == 4, "Only 32- or 4-byte hashes can be used for add chunks.");
- Prefix hash;
-- hash.FromPlaintext(line, mCryptoHash);
-+ hash.FromPlaintext(line);
- nsresult rv = mTableUpdate->NewAddPrefix(mChunkState.num, hash);
- if (NS_FAILED(rv)) {
- return rv;
-@@ -433,7 +426,7 @@ ProtocolParserV2::ProcessPlaintextChunk(const nsACString& aChunk)
-
- if (mChunkState.hashSize == COMPLETE_SIZE) {
- Completion hash;
-- hash.FromPlaintext(Substring(iter, end), mCryptoHash);
-+ hash.FromPlaintext(Substring(iter, end));
- nsresult rv = mTableUpdate->NewSubComplete(addChunk, hash, mChunkState.num);
- if (NS_FAILED(rv)) {
- return rv;
-@@ -441,7 +434,7 @@ ProtocolParserV2::ProcessPlaintextChunk(const nsACString& aChunk)
- } else {
- NS_ASSERTION(mChunkState.hashSize == 4, "Only 32- or 4-byte hashes can be used for add chunks.");
- Prefix hash;
-- hash.FromPlaintext(Substring(iter, end), mCryptoHash);
-+ hash.FromPlaintext(Substring(iter, end));
- nsresult rv = mTableUpdate->NewSubPrefix(addChunk, hash, mChunkState.num);
- if (NS_FAILED(rv)) {
- return rv;
-diff --git toolkit/components/url-classifier/ProtocolParser.h toolkit/components/url-classifier/ProtocolParser.h
-index 329911621f18..066e8892df7b 100644
---- toolkit/components/url-classifier/ProtocolParser.h
-+++ toolkit/components/url-classifier/ProtocolParser.h
-@@ -7,7 +7,6 @@
- #define ProtocolParser_h__
-
- #include "HashStore.h"
--#include "nsICryptoHMAC.h"
- #include "safebrowsing.pb.h"
-
- namespace mozilla {
-@@ -28,8 +27,6 @@ public:
-
- nsresult Status() const { return mUpdateStatus; }
-
-- nsresult Init(nsICryptoHash* aHasher);
--
- #ifdef MOZ_SAFEBROWSING_DUMP_FAILED_UPDATES
- virtual nsCString GetRawTableUpdates() const { return mPending; }
- #endif
-@@ -73,7 +70,6 @@ protected:
- nsTArray<TableUpdate*> mTableUpdates;
-
- nsTArray<ForwardedUpdate> mForwards;
-- nsCOMPtr<nsICryptoHash> mCryptoHash;
-
- // The table names that were requested from the client.
- nsTArray<nsCString> mRequestedTables;
-diff --git toolkit/components/url-classifier/nsUrlClassifierDBService.cpp toolkit/components/url-classifier/nsUrlClassifierDBService.cpp
-index 6d82c25de7cf..40de1b4130b0 100644
---- toolkit/components/url-classifier/nsUrlClassifierDBService.cpp
-+++ toolkit/components/url-classifier/nsUrlClassifierDBService.cpp
-@@ -8,8 +8,6 @@
- #include "nsAppDirectoryServiceDefs.h"
- #include "nsArrayUtils.h"
- #include "nsCRT.h"
--#include "nsICryptoHash.h"
--#include "nsICryptoHMAC.h"
- #include "nsIDirectoryService.h"
- #include "nsIKeyModule.h"
- #include "nsIObserverService.h"
-@@ -467,8 +465,6 @@ nsUrlClassifierDBServiceWorker::BeginStream(const nsACString &table)
- return NS_ERROR_OUT_OF_MEMORY;
- }
-
-- mProtocolParser->Init(mCryptoHash);
--
- if (!table.IsEmpty()) {
- mProtocolParser->SetCurrentTable(table);
- }
-@@ -809,7 +805,6 @@ nsUrlClassifierDBServiceWorker::CloseDb()
- mClassifier = nullptr;
- }
-
-- mCryptoHash = nullptr;
- LOG(("urlclassifier db closed\n"));
-
- return NS_OK;
-@@ -944,9 +939,6 @@ nsUrlClassifierDBServiceWorker::OpenDb()
- }
-
- nsresult rv;
-- mCryptoHash = do_CreateInstance(NS_CRYPTO_HASH_CONTRACTID, &rv);
-- NS_ENSURE_SUCCESS(rv, rv);
--
- nsAutoPtr<Classifier> classifier(new (fallible) Classifier());
- if (!classifier) {
- return NS_ERROR_OUT_OF_MEMORY;
-diff --git toolkit/components/url-classifier/nsUrlClassifierDBService.h toolkit/components/url-classifier/nsUrlClassifierDBService.h
-index 8d284f5b0842..a4c5952e91bb 100644
---- toolkit/components/url-classifier/nsUrlClassifierDBService.h
-+++ toolkit/components/url-classifier/nsUrlClassifierDBService.h
-@@ -270,9 +270,6 @@ private:
-
- bool IsSameAsLastResults(CacheResultArray& aResult);
-
-- // Can only be used on the background thread
-- nsCOMPtr<nsICryptoHash> mCryptoHash;
--
- nsAutoPtr<mozilla::safebrowsing::Classifier> mClassifier;
- // The class that actually parses the update chunks.
- nsAutoPtr<ProtocolParser> mProtocolParser;
-diff --git toolkit/components/url-classifier/tests/gtest/Common.cpp toolkit/components/url-classifier/tests/gtest/Common.cpp
-index 2d11cf87ccca..812151f569a4 100644
---- toolkit/components/url-classifier/tests/gtest/Common.cpp
-+++ toolkit/components/url-classifier/tests/gtest/Common.cpp
-@@ -152,8 +152,7 @@ nsCString
- GeneratePrefix(const nsCString& aFragment, uint8_t aLength)
- {
- Completion complete;
-- nsCOMPtr<nsICryptoHash> cryptoHash = do_CreateInstance(NS_CRYPTO_HASH_CONTRACTID);
-- complete.FromPlaintext(aFragment, cryptoHash);
-+ complete.FromPlaintext(aFragment);
-
- nsCString hash;
- hash.Assign((const char *)complete.buf, aLength);
-diff --git toolkit/components/url-classifier/tests/gtest/TestCaching.cpp toolkit/components/url-classifier/tests/gtest/TestCaching.cpp
-index b280f7c61af6..7a9f5cdbb0e7 100644
---- toolkit/components/url-classifier/tests/gtest/TestCaching.cpp
-+++ toolkit/components/url-classifier/tests/gtest/TestCaching.cpp
-@@ -18,14 +18,11 @@ SetupCacheEntry(LookupCacheV2* aLookupCache,
- MissPrefixArray misses;
- MissPrefixArray emptyMisses;
-
-- nsCOMPtr<nsICryptoHash> cryptoHash =
-- do_CreateInstance(NS_CRYPTO_HASH_CONTRACTID);
--
- AddComplete* add = completes.AppendElement(fallible);
-- add->complete.FromPlaintext(aCompletion, cryptoHash);
-+ add->complete.FromPlaintext(aCompletion);
-
- Prefix* prefix = misses.AppendElement(fallible);
-- prefix->FromPlaintext(aCompletion, cryptoHash);
-+ prefix->FromPlaintext(aCompletion);
-
- // Setup positive cache first otherwise negative cache expiry will be
- // overwritten.
-@@ -45,9 +42,7 @@ SetupCacheEntry(LookupCacheV4* aLookupCache,
- FullHashResponseMap map;
-
- Prefix prefix;
-- nsCOMPtr<nsICryptoHash> cryptoHash =
-- do_CreateInstance(NS_CRYPTO_HASH_CONTRACTID);
-- prefix.FromPlaintext(aCompletion, cryptoHash);
-+ prefix.FromPlaintext(aCompletion);
-
- CachedFullHashResponse* response = map.LookupOrAdd(prefix.ToUint32());
-
-@@ -104,8 +99,7 @@ TestCache(const _Fragment& aFragment,
- T* aCache = nullptr)
- {
- Completion lookupHash;
-- nsCOMPtr<nsICryptoHash> cryptoHash = do_CreateInstance(NS_CRYPTO_HASH_CONTRACTID);
-- lookupHash.FromPlaintext(aFragment, cryptoHash);
-+ lookupHash.FromPlaintext(aFragment);
-
- TestCache<T>(lookupHash, aExpectedHas, aExpectedConfirmed, aExpectedInCache, aCache);
- }
-@@ -148,13 +142,12 @@ TEST(UrlClassifierCaching, InNegativeCacheNotExpired)
- {
- // Create a fullhash whose prefix matches the prefix in negative cache
- // but completion doesn't match any fullhash in positive cache.
-- nsCOMPtr<nsICryptoHash> cryptoHash = do_CreateInstance(NS_CRYPTO_HASH_CONTRACTID);
-
- Completion prefix;
-- prefix.FromPlaintext(_Fragment("cache.notexpired.com/"), cryptoHash);
-+ prefix.FromPlaintext(_Fragment("cache.notexpired.com/"));
-
- Completion fullhash;
-- fullhash.FromPlaintext(_Fragment("firefox.com/"), cryptoHash);
-+ fullhash.FromPlaintext(_Fragment("firefox.com/"));
-
- // Overwrite the 4-byte prefix of `fullhash` so that it conflicts with `prefix`.
- // Since "cache.notexpired.com" is added to database in TestCache as a
-@@ -171,13 +164,12 @@ TEST(UrlClassifierCaching, InNegativeCacheNotExpired)
- TEST(UrlClassifierCaching, InNegativeCacheExpired)
- {
- // Create a fullhash whose prefix is in the cache.
-- nsCOMPtr<nsICryptoHash> cryptoHash = do_CreateInstance(NS_CRYPTO_HASH_CONTRACTID);
-
- Completion prefix;
-- prefix.FromPlaintext(_Fragment("cache.expired.com/"), cryptoHash);
-+ prefix.FromPlaintext(_Fragment("cache.expired.com/"));
-
- Completion fullhash;
-- fullhash.FromPlaintext(_Fragment("firefox.com/"), cryptoHash);
-+ fullhash.FromPlaintext(_Fragment("firefox.com/"));
-
- memcpy(fullhash.buf, prefix.buf, 10);
-
-@@ -255,7 +247,7 @@ TEST(UrlClassifierCaching, NegativeCacheExpireV2)
-
- MissPrefixArray misses;
- Prefix* prefix = misses.AppendElement(fallible);
-- prefix->FromPlaintext(NEG_CACHE_EXPIRED_URL, cryptoHash);
-+ prefix->FromPlaintext(NEG_CACHE_EXPIRED_URL);
-
- AddCompleteArray dummy;
- cache->AddGethashResultToCache(dummy, misses, EXPIRED_TIME_SEC);
-@@ -275,7 +267,7 @@ TEST(UrlClassifierCaching, NegativeCacheExpireV4)
- FullHashResponseMap map;
- Prefix prefix;
- nsCOMPtr<nsICryptoHash> cryptoHash = do_CreateInstance(NS_CRYPTO_HASH_CONTRACTID);
-- prefix.FromPlaintext(NEG_CACHE_EXPIRED_URL, cryptoHash);
-+ prefix.FromPlaintext(NEG_CACHE_EXPIRED_URL);
- CachedFullHashResponse* response = map.LookupOrAdd(prefix.ToUint32());
-
- response->negativeCacheExpirySec = EXPIRED_TIME_SEC;
-diff --git toolkit/components/url-classifier/tests/gtest/TestClassifier.cpp toolkit/components/url-classifier/tests/gtest/TestClassifier.cpp
-index a4d21581315e..23b7e9ef59d1 100644
---- toolkit/components/url-classifier/tests/gtest/TestClassifier.cpp
-+++ toolkit/components/url-classifier/tests/gtest/TestClassifier.cpp
-@@ -71,8 +71,7 @@ TestReadNoiseEntries(Classifier* classifier,
- const nsCString& aFragment)
- {
- Completion lookupHash;
-- nsCOMPtr<nsICryptoHash> cryptoHash = do_CreateInstance(NS_CRYPTO_HASH_CONTRACTID);
-- lookupHash.FromPlaintext(aFragment, cryptoHash);
-+ lookupHash.FromPlaintext(aFragment);
- LookupResult result;
- result.hash.complete = lookupHash;
-
-diff --git toolkit/components/url-classifier/tests/gtest/TestLookupCacheV4.cpp toolkit/components/url-classifier/tests/gtest/TestLookupCacheV4.cpp
-index b2ed091ae308..3fbea2d9d475 100644
---- toolkit/components/url-classifier/tests/gtest/TestLookupCacheV4.cpp
-+++ toolkit/components/url-classifier/tests/gtest/TestLookupCacheV4.cpp
-@@ -17,8 +17,7 @@ TestHasPrefix(const _Fragment& aFragment, bool aExpectedHas, bool aExpectedCompl
- UniquePtr<LookupCache> cache = SetupLookupCache<LookupCacheV4>(array);
-
- Completion lookupHash;
-- nsCOMPtr<nsICryptoHash> cryptoHash = do_CreateInstance(NS_CRYPTO_HASH_CONTRACTID);
-- lookupHash.FromPlaintext(aFragment, cryptoHash);
-+ lookupHash.FromPlaintext(aFragment);
-
- bool has, confirmed;
- uint32_t matchLength;
-diff --git toolkit/components/url-classifier/tests/unit/head_urlclassifier.js toolkit/components/url-classifier/tests/unit/head_urlclassifier.js
-index f52ded37c2e9..61b0c170d457 100644
---- toolkit/components/url-classifier/tests/unit/head_urlclassifier.js
-+++ toolkit/components/url-classifier/tests/unit/head_urlclassifier.js
-@@ -17,6 +17,9 @@ do_get_profile();
-
- var dirSvc = Cc["@mozilla.org/file/directory_service;1"].getService(Ci.nsIProperties);
-
-+// Ensure PSM is initialized before the test
-+Cc["@mozilla.org/psm;1"].getService(Ci.nsISupports);
-+
- var iosvc = Cc["@mozilla.org/network/io-service;1"].getService(Ci.nsIIOService);
-
- var secMan = Cc["@mozilla.org/scriptsecuritymanager;1"]
diff --git a/www/firefox/files/patch-bug1394265 b/www/firefox/files/patch-bug1394265
deleted file mode 100644
index 15d00bc63722..000000000000
--- a/www/firefox/files/patch-bug1394265
+++ /dev/null
@@ -1,24 +0,0 @@
-commit a51675964a63
-Author: Jeff Gilbert <jgilbert@mozilla.com>
-Date: Tue Oct 17 17:14:29 2017 -0700
-
- Bug 1394265 - Set MAX_COMBINED_TEXTURE_IMAGE_UNITS to 0 if GetIntegeriv fails. - r=daoshengmu a=ritu
-
- MozReview-Commit-ID: 5h6UPXczKhb
----
- dom/canvas/WebGLContextValidate.cpp | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git dom/canvas/WebGLContextValidate.cpp dom/canvas/WebGLContextValidate.cpp
-index a8334e546414..ebf0aa8c2d78 100644
---- dom/canvas/WebGLContextValidate.cpp
-+++ dom/canvas/WebGLContextValidate.cpp
-@@ -554,7 +554,7 @@ WebGLContext::InitAndValidateGL(FailureReason* const out_failReason)
- if (MinCapabilityMode())
- mGLMaxTextureUnits = MINVALUE_GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS;
- else
-- gl->fGetIntegerv(LOCAL_GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS, &mGLMaxTextureUnits);
-+ mGLMaxTextureUnits = gl->GetIntAs<GLint>(LOCAL_GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS);
-
- if (mGLMaxTextureUnits < 8) {
- const nsPrintfCString reason("GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS: %d is < 8!",
diff --git a/www/firefox/files/patch-bug1394530 b/www/firefox/files/patch-bug1394530
deleted file mode 100644
index 92b6e587ce1d..000000000000
--- a/www/firefox/files/patch-bug1394530
+++ /dev/null
@@ -1,60 +0,0 @@
-commit a2b75aa9409c
-Author: Tooru Fujisawa <arai_a@mac.com>
-Date: Sun Sep 17 19:52:04 2017 +0900
-
- Bug 1394530 - Stop using optimized path for non PromiseObject. r=till, a=sledru
-
- --HG--
- extra : source : 079ff8998fd50540948d3262a3a8b1f4d61b43e9
----
- js/src/builtin/Promise.cpp | 21 ++++++++++++++++-----
- 1 file changed, 16 insertions(+), 5 deletions(-)
-
-diff --git js/src/builtin/Promise.cpp js/src/builtin/Promise.cpp
-index 1cb1cff0682e..e316f090504d 100644
---- js/src/builtin/Promise.cpp
-+++ js/src/builtin/Promise.cpp
-@@ -2365,6 +2365,15 @@ NewReactionRecord(JSContext* cx, HandleObject resultPromise, HandleValue onFulfi
- HandleValue onRejected, HandleObject resolve, HandleObject reject,
- HandleObject incumbentGlobalObject)
- {
-+ // Either of the following conditions must be met:
-+ // * resultPromise is a PromiseObject
-+ // * resolve and reject are callable
-+ // except for Async Generator, there resultPromise can be nullptr.
-+ MOZ_ASSERT_IF(resultPromise && !resultPromise->is<PromiseObject>(), resolve);
-+ MOZ_ASSERT_IF(resultPromise && !resultPromise->is<PromiseObject>(), IsCallable(resolve));
-+ MOZ_ASSERT_IF(resultPromise && !resultPromise->is<PromiseObject>(), reject);
-+ MOZ_ASSERT_IF(resultPromise && !resultPromise->is<PromiseObject>(), IsCallable(reject));
-+
- Rooted<PromiseReactionRecord*> reaction(cx, NewObjectWithClassProto<PromiseReactionRecord>(cx));
- if (!reaction)
- return nullptr;
-@@ -3072,7 +3081,7 @@ BlockOnPromise(JSContext* cx, HandleValue promiseVal, HandleObject blockedPromis
- // rejected promises list.
- bool addToDependent = true;
-
-- if (C == PromiseCtor) {
-+ if (C == PromiseCtor && resultPromise->is<PromiseObject>()) {
- addToDependent = false;
- } else {
- // 25.4.5.3., step 4.
-@@ -3131,12 +3140,14 @@ BlockOnPromise(JSContext* cx, HandleValue promiseVal, HandleObject blockedPromis
- return false;
- }
-
-- // If the object to depend on isn't a, maybe-wrapped, Promise instance,
-- // we ignore it. All this does is lose some small amount of debug
-- // information in scenarios that are highly unlikely to occur in useful
-- // code.
-+ // If either the object to depend on or the object that gets blocked isn't
-+ // a, maybe-wrapped, Promise instance, we ignore it. All this does is lose
-+ // some small amount of debug information in scenarios that are highly
-+ // unlikely to occur in useful code.
- if (!unwrappedPromiseObj->is<PromiseObject>())
- return true;
-+ if (!blockedPromise_->is<PromiseObject>())
-+ return true;
-
- Rooted<PromiseObject*> promise(cx, &unwrappedPromiseObj->as<PromiseObject>());
- return AddPromiseReaction(cx, promise, UndefinedHandleValue, UndefinedHandleValue,
diff --git a/www/firefox/files/patch-bug1395138 b/www/firefox/files/patch-bug1395138
deleted file mode 100644
index 5422a708ab5c..000000000000
--- a/www/firefox/files/patch-bug1395138
+++ /dev/null
@@ -1,49 +0,0 @@
-commit 8ab8a207d511
-Author: Jamie Nicol <jnicol@mozilla.com>
-Date: Mon Oct 9 17:48:59 2017 +0100
-
- Bug 1395138 - Hold reference to layers in ContainerLayerComposite::mPrepared. r=mattwoodrow, a=sledru
-
- MozReview-Commit-ID: 6qUDRnRcFAw
----
- gfx/layers/composite/ContainerLayerComposite.cpp | 9 +++++----
- 1 file changed, 5 insertions(+), 4 deletions(-)
-
-diff --git gfx/layers/composite/ContainerLayerComposite.cpp gfx/layers/composite/ContainerLayerComposite.cpp
-index aad2993629fc..28d9e79925a0 100755
---- gfx/layers/composite/ContainerLayerComposite.cpp
-+++ gfx/layers/composite/ContainerLayerComposite.cpp
-@@ -161,12 +161,12 @@ static gfx::IntRect ContainerVisibleRect(ContainerT* aContainer)
- /* all of the per-layer prepared data we need to maintain */
- struct PreparedLayer
- {
-- PreparedLayer(LayerComposite *aLayer,
-+ PreparedLayer(Layer *aLayer,
- RenderTargetIntRect aClipRect,
- Maybe<gfx::Polygon>&& aGeometry)
- : mLayer(aLayer), mClipRect(aClipRect), mGeometry(Move(aGeometry)) {}
-
-- LayerComposite* mLayer;
-+ RefPtr<Layer> mLayer;
- RenderTargetIntRect mClipRect;
- Maybe<Polygon> mGeometry;
- };
-@@ -230,7 +230,8 @@ ContainerPrepare(ContainerT* aContainer,
- CULLING_LOG("Preparing sublayer %p\n", layerToRender->GetLayer());
-
- layerToRender->Prepare(clipRect);
-- aContainer->mPrepared->mLayers.AppendElement(PreparedLayer(layerToRender, clipRect,
-+ aContainer->mPrepared->mLayers.AppendElement(PreparedLayer(layerToRender->GetLayer(),
-+ clipRect,
- Move(layer.geometry)));
- }
-
-@@ -408,7 +409,7 @@ RenderLayers(ContainerT* aContainer, LayerManagerComposite* aManager,
- PreparedLayer& preparedData = aContainer->mPrepared->mLayers[i];
-
- const gfx::IntRect clipRect = preparedData.mClipRect.ToUnknownRect();
-- LayerComposite* layerToRender = preparedData.mLayer;
-+ LayerComposite* layerToRender = static_cast<LayerComposite*>(preparedData.mLayer->ImplData());
- const Maybe<gfx::Polygon>& childGeometry = preparedData.mGeometry;
-
- Layer* layer = layerToRender->GetLayer();
diff --git a/www/firefox/files/patch-bug1397811 b/www/firefox/files/patch-bug1397811
deleted file mode 100644
index 4df98338ece5..000000000000
--- a/www/firefox/files/patch-bug1397811
+++ /dev/null
@@ -1,48 +0,0 @@
-commit 2bffd0136caf
-Author: Olli Pettay <Olli.Pettay@helsinki.fi>
-Date: Fri Oct 20 11:02:29 2017 +0100
-
- Bug 1397811 - In order to not leak properties, ensure all the properties of adopted nodes are removed in case the adopt call fails. r=bz, a=lizzard
-
- --HG--
- extra : source : b609906f34b50f8e4236d0fee8d01338181dd906
----
- dom/base/nsNodeUtils.cpp | 21 +++++++++------------
- 1 file changed, 9 insertions(+), 12 deletions(-)
-
-diff --git dom/base/nsNodeUtils.cpp dom/base/nsNodeUtils.cpp
-index dd958aa443ce..20e714d54065 100644
---- dom/base/nsNodeUtils.cpp
-+++ dom/base/nsNodeUtils.cpp
-@@ -605,6 +605,15 @@ nsNodeUtils::CloneAndAdopt(nsINode *aNode, bool aClone, bool aDeep,
- }
- }
-
-+ if (aNodesWithProperties && aNode->HasProperties()) {
-+ bool ok = aNodesWithProperties->AppendObject(aNode);
-+ MOZ_RELEASE_ASSERT(ok, "Out of memory");
-+ if (aClone) {
-+ ok = aNodesWithProperties->AppendObject(clone);
-+ MOZ_RELEASE_ASSERT(ok, "Out of memory");
-+ }
-+ }
-+
- if (aDeep && (!aClone || !aNode->IsNodeOfType(nsINode::eATTRIBUTE))) {
- // aNode's children.
- for (nsIContent* cloneChild = aNode->GetFirstChild();
-@@ -664,15 +673,6 @@ nsNodeUtils::CloneAndAdopt(nsINode *aNode, bool aClone, bool aDeep,
- }
- #endif
-
-- if (aNodesWithProperties && aNode->HasProperties()) {
-- bool ok = aNodesWithProperties->AppendObject(aNode);
-- if (aClone) {
-- ok = ok && aNodesWithProperties->AppendObject(clone);
-- }
--
-- NS_ENSURE_TRUE(ok, NS_ERROR_OUT_OF_MEMORY);
-- }
--
- clone.forget(aResult);
-
- return NS_OK;
diff --git a/www/firefox/files/patch-bug1399922 b/www/firefox/files/patch-bug1399922
deleted file mode 100644
index 5cc1c37ca489..000000000000
--- a/www/firefox/files/patch-bug1399922
+++ /dev/null
@@ -1,104 +0,0 @@
-commit aec4b24e060f
-Author: Jan-Ivar Bruaroey <jib@mozilla.com>
-Date: Thu Sep 21 10:45:56 2017 -0400
-
- Bug 1399922 - Use a static mutex for getting deviceId keys in MediaParent. r=jesup, a=sledru
-
- MozReview-Commit-ID: E6pzyAM4jOQ
-
- --HG--
- extra : source : b030607a3ddbc015d30dbffc5eba0789cae6db62
----
- dom/media/systemservices/MediaParent.cpp | 32 +++++++++++++++++++++-----------
- 1 file changed, 21 insertions(+), 11 deletions(-)
-
-diff --git dom/media/systemservices/MediaParent.cpp dom/media/systemservices/MediaParent.cpp
-index c7798dd73dc6..485f9bdee808 100644
---- dom/media/systemservices/MediaParent.cpp
-+++ dom/media/systemservices/MediaParent.cpp
-@@ -37,6 +37,7 @@ mozilla::LazyLogModule gMediaParentLog("MediaParent");
- namespace mozilla {
- namespace media {
-
-+StaticMutex sOriginKeyStoreMutex;
- static OriginKeyStore* sOriginKeyStore = nullptr;
-
- class OriginKeyStore : public nsISupports
-@@ -396,6 +397,7 @@ class OriginKeyStore : public nsISupports
- private:
- virtual ~OriginKeyStore()
- {
-+ StaticMutexAutoLock lock(sOriginKeyStoreMutex);
- sOriginKeyStore = nullptr;
- LOG((__FUNCTION__));
- }
-@@ -404,6 +406,7 @@ public:
- static OriginKeyStore* Get()
- {
- MOZ_ASSERT(NS_IsMainThread());
-+ StaticMutexAutoLock lock(sOriginKeyStoreMutex);
- if (!sOriginKeyStore) {
- sOriginKeyStore = new OriginKeyStore();
- }
-@@ -447,8 +450,8 @@ Parent<Super>::RecvGetPrincipalKey(const uint32_t& aRequestId,
- return IPCResult(this, false);
- }
-
-- // Then over to stream-transport thread to do the actual file io.
-- // Stash a pledge to hold the answer and get an id for this request.
-+ // Then over to stream-transport thread (a thread pool) to do the actual
-+ // file io. Stash a pledge to hold the answer and get an id for this request.
-
- RefPtr<Pledge<nsCString>> p = new Pledge<nsCString>();
- uint32_t id = mOutstandingPledges.Append(*p);
-@@ -460,14 +463,18 @@ Parent<Super>::RecvGetPrincipalKey(const uint32_t& aRequestId,
- rv = sts->Dispatch(NewRunnableFrom([this, that, id, profileDir,
- aPrincipalInfo, aPersist]() -> nsresult {
- MOZ_ASSERT(!NS_IsMainThread());
-- mOriginKeyStore->mOriginKeys.SetProfileDir(profileDir);
-+ StaticMutexAutoLock lock(sOriginKeyStoreMutex);
-+ if (!sOriginKeyStore) {
-+ return NS_ERROR_FAILURE;
-+ }
-+ sOriginKeyStore->mOriginKeys.SetProfileDir(profileDir);
-
- nsresult rv;
- nsAutoCString result;
- if (IsPincipalInfoPrivate(aPrincipalInfo)) {
-- rv = mOriginKeyStore->mPrivateBrowsingOriginKeys.GetPrincipalKey(aPrincipalInfo, result);
-+ rv = sOriginKeyStore->mPrivateBrowsingOriginKeys.GetPrincipalKey(aPrincipalInfo, result);
- } else {
-- rv = mOriginKeyStore->mOriginKeys.GetPrincipalKey(aPrincipalInfo, result, aPersist);
-+ rv = sOriginKeyStore->mOriginKeys.GetPrincipalKey(aPrincipalInfo, result, aPersist);
- }
-
- if (NS_WARN_IF(NS_FAILED(rv))) {
-@@ -518,19 +525,22 @@ Parent<Super>::RecvSanitizeOriginKeys(const uint64_t& aSinceWhen,
- if (NS_WARN_IF(NS_FAILED(rv))) {
- return IPCResult(this, false);
- }
-- // Over to stream-transport thread to do the file io.
-+ // Over to stream-transport thread (a thread pool) to do the file io.
-
- nsCOMPtr<nsIEventTarget> sts = do_GetService(NS_STREAMTRANSPORTSERVICE_CONTRACTID);
- MOZ_ASSERT(sts);
-- RefPtr<OriginKeyStore> store(mOriginKeyStore);
-
-- rv = sts->Dispatch(NewRunnableFrom([profileDir, store, aSinceWhen,
-+ rv = sts->Dispatch(NewRunnableFrom([profileDir, aSinceWhen,
- aOnlyPrivateBrowsing]() -> nsresult {
- MOZ_ASSERT(!NS_IsMainThread());
-- store->mPrivateBrowsingOriginKeys.Clear(aSinceWhen);
-+ StaticMutexAutoLock lock(sOriginKeyStoreMutex);
-+ if (!sOriginKeyStore) {
-+ return NS_ERROR_FAILURE;
-+ }
-+ sOriginKeyStore->mPrivateBrowsingOriginKeys.Clear(aSinceWhen);
- if (!aOnlyPrivateBrowsing) {
-- store->mOriginKeys.SetProfileDir(profileDir);
-- store->mOriginKeys.Clear(aSinceWhen);
-+ sOriginKeyStore->mOriginKeys.SetProfileDir(profileDir);
-+ sOriginKeyStore->mOriginKeys.Clear(aSinceWhen);
- }
- return NS_OK;
- }), NS_DISPATCH_NORMAL);
diff --git a/www/firefox/files/patch-bug1400003 b/www/firefox/files/patch-bug1400003
deleted file mode 100644
index 5039150992e6..000000000000
--- a/www/firefox/files/patch-bug1400003
+++ /dev/null
@@ -1,120 +0,0 @@
-commit 677c707a4f11
-Author: Jon Coppeard <jcoppeard@mozilla.com>
-Date: Mon Oct 9 10:03:20 2017 +0100
-
- Bug 1400003 - Mark Heap<T> and barrier classes as MOZ_NON_MEMMOVABLE. r=sfink, r=froydnj, a=lizzard
-
- --HG--
- extra : source : 6ad5b916c9659aeb4b901d8f9ec7f121dc2c4418
----
- js/public/RootingAPI.h | 10 +++++++++-
- js/src/gc/Barrier.h | 5 ++++-
- xpcom/ds/nsTArray.h | 27 +++++++++++++--------------
- 3 files changed, 26 insertions(+), 16 deletions(-)
-
-diff --git js/public/RootingAPI.h js/public/RootingAPI.h
-index 74a61af93703..f8ec7c5a1f5b 100644
---- js/public/RootingAPI.h
-+++ js/public/RootingAPI.h
-@@ -231,7 +231,7 @@ AssertGCThingIsNotAnObjectSubclass(js::gc::Cell* cell) {}
- * Type T must be a public GC pointer type.
- */
- template <typename T>
--class Heap : public js::HeapBase<T, Heap<T>>
-+class MOZ_NON_MEMMOVABLE Heap : public js::HeapBase<T, Heap<T>>
- {
- // Please note: this can actually also be used by nsXBLMaybeCompiled<T>, for legacy reasons.
- static_assert(js::IsHeapConstructibleType<T>::value,
-@@ -1246,6 +1246,14 @@ class JS_PUBLIC_API(ObjectPtr)
-
- explicit ObjectPtr(JSObject* obj) : value(obj) {}
-
-+ ObjectPtr(const ObjectPtr& other) : value(other.value) {}
-+
-+ ObjectPtr(ObjectPtr&& other)
-+ : value(other.value)
-+ {
-+ other.value = nullptr;
-+ }
-+
- /* Always call finalize before the destructor. */
- ~ObjectPtr() { MOZ_ASSERT(!value); }
-
-diff --git js/src/gc/Barrier.h js/src/gc/Barrier.h
-index 9c4f53975752..1740315c14e9 100644
---- js/src/gc/Barrier.h
-+++ js/src/gc/Barrier.h
-@@ -318,8 +318,11 @@ struct InternalBarrierMethods<jsid>
- };
-
- // Base class of all barrier types.
-+//
-+// This is marked non-memmovable since post barriers added by derived classes
-+// can add pointers to class instances to the store buffer.
- template <typename T>
--class BarrieredBase
-+class MOZ_NON_MEMMOVABLE BarrieredBase
- {
- protected:
- // BarrieredBase is not directly instantiable.
-diff --git xpcom/ds/nsTArray.h xpcom/ds/nsTArray.h
-index 424a50ba421e..4e9b57126bfb 100644
---- xpcom/ds/nsTArray.h
-+++ xpcom/ds/nsTArray.h
-@@ -37,6 +37,7 @@
- namespace JS {
- template<class T>
- class Heap;
-+class ObjectPtr;
- } /* namespace JS */
-
- class nsRegion;
-@@ -708,7 +709,7 @@ struct nsTArray_CopyWithConstructors
- template<class E>
- struct MOZ_NEEDS_MEMMOVABLE_TYPE nsTArray_CopyChooser
- {
-- typedef nsTArray_CopyWithMemutils Type;
-+ using Type = nsTArray_CopyWithMemutils;
- };
-
- //
-@@ -719,14 +720,18 @@ struct MOZ_NEEDS_MEMMOVABLE_TYPE nsTArray_CopyChooser
- template<> \
- struct nsTArray_CopyChooser<T> \
- { \
-- typedef nsTArray_CopyWithConstructors<T> Type; \
-+ using Type = nsTArray_CopyWithConstructors<T>; \
- };
-
--template<class E>
--struct nsTArray_CopyChooser<JS::Heap<E>>
--{
-- typedef nsTArray_CopyWithConstructors<JS::Heap<E>> Type;
--};
-+#define DECLARE_USE_COPY_CONSTRUCTORS_FOR_TEMPLATE(T) \
-+ template<typename S> \
-+ struct nsTArray_CopyChooser<T<S>> \
-+ { \
-+ using Type = nsTArray_CopyWithConstructors<T<S>>; \
-+ };
-+
-+DECLARE_USE_COPY_CONSTRUCTORS_FOR_TEMPLATE(JS::Heap)
-+DECLARE_USE_COPY_CONSTRUCTORS_FOR_TEMPLATE(std::function)
-
- DECLARE_USE_COPY_CONSTRUCTORS(nsRegion)
- DECLARE_USE_COPY_CONSTRUCTORS(nsIntRegion)
-@@ -740,13 +745,7 @@ DECLARE_USE_COPY_CONSTRUCTORS(mozilla::dom::indexedDB::SerializedStructuredClone
- DECLARE_USE_COPY_CONSTRUCTORS(JSStructuredCloneData)
- DECLARE_USE_COPY_CONSTRUCTORS(mozilla::dom::MessagePortMessage)
- DECLARE_USE_COPY_CONSTRUCTORS(mozilla::SourceBufferTask)
--
--template<typename T>
--struct nsTArray_CopyChooser<std::function<T>>
--{
-- typedef nsTArray_CopyWithConstructors<std::function<T>> Type;
--};
--
-+DECLARE_USE_COPY_CONSTRUCTORS(JS::ObjectPtr)
-
- //
- // Base class for nsTArray_Impl that is templated on element type and derived
diff --git a/www/firefox/files/patch-bug1400554 b/www/firefox/files/patch-bug1400554
deleted file mode 100644
index b8ed7dec089a..000000000000
--- a/www/firefox/files/patch-bug1400554
+++ /dev/null
@@ -1,27 +0,0 @@
-commit 62b41b600acc
-Author: Dragana Damjanovic <dd.mozilla@gmail.com>
-Date: Mon Oct 9 14:59:32 2017 -0400
-
- Bug 1400554 - Cancel a time in TLSFilterTransaction if transaction is canceled. r=mcmanus, a=ritu
-
- --HG--
- extra : source : 67315954145e9cae0efe8c5323452a70a13c5484
----
- netwerk/protocol/http/TunnelUtils.cpp | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git netwerk/protocol/http/TunnelUtils.cpp netwerk/protocol/http/TunnelUtils.cpp
-index d0f6ef0b1873..0cf3ea4f3008 100644
---- netwerk/protocol/http/TunnelUtils.cpp
-+++ netwerk/protocol/http/TunnelUtils.cpp
-@@ -126,6 +126,10 @@ TLSFilterTransaction::Close(nsresult aReason)
- return;
- }
-
-+ if (mTimer) {
-+ mTimer->Cancel();
-+ mTimer = nullptr;
-+ }
- mTransaction->Close(aReason);
- mTransaction = nullptr;
- }
diff --git a/www/firefox/files/patch-bug1401339 b/www/firefox/files/patch-bug1401339
deleted file mode 100644
index 74ebcd724bb4..000000000000
--- a/www/firefox/files/patch-bug1401339
+++ /dev/null
@@ -1,76 +0,0 @@
-commit 5d3c733f43dd
-Author: Gabriele Svelto <gsvelto@mozilla.com>
-Date: Fri Sep 22 15:06:22 2017 +0200
-
- Bug 1401339 - Look for libcurl under platform-specific paths; r=Dexter a=sylvestre
-
- MozReview-Commit-ID: 6wijqLsar56
-
- --HG--
- extra : source : ebd3c3b2d64442c2b5eb7ab3e87c4b423311f3f4
----
- .../pingsender/pingsender_unix_common.cpp | 40 +++++++++++++++-------
- 1 file changed, 28 insertions(+), 12 deletions(-)
-
-diff --git toolkit/components/telemetry/pingsender/pingsender_unix_common.cpp toolkit/components/telemetry/pingsender/pingsender_unix_common.cpp
-index b1cea81f6288..ae20f4114193 100644
---- toolkit/components/telemetry/pingsender/pingsender_unix_common.cpp
-+++ toolkit/components/telemetry/pingsender/pingsender_unix_common.cpp
-@@ -80,29 +80,45 @@ CurlWrapper::~CurlWrapper()
- bool
- CurlWrapper::Init()
- {
-- // libcurl might show up under different names, try them all until we find it
-+ const char* libcurlPaths[] = {
-+ "/usr/lib",
-+#ifdef XP_LINUX
-+ "/usr/lib32",
-+ "/usr/lib64",
-+ "/usr/lib/i386-linux-gnu", // Debian 32-bit x86
-+ "/usr/lib/x86_64-linux-gnu", // Debian 64-bit x86
-+#endif // XP_LINUX
-+ };
-+
- const char* libcurlNames[] = {
-+#ifdef XP_LINUX
- "libcurl.so",
- "libcurl.so.4",
- // Debian gives libcurl a different name when it is built against GnuTLS
-+ "libcurl-gnutls.so",
- "libcurl-gnutls.so.4",
-- // Older libcurl if we can't find anything better
-+ // Older versions in case we find nothing better
- "libcurl.so.3",
--#ifndef HAVE_64BIT_BUILD
-- // 32-bit versions on 64-bit hosts
-- "/usr/lib32/libcurl.so",
-- "/usr/lib32/libcurl.so.4",
-- "/usr/lib32/libcurl-gnutls.so.4",
-- "/usr/lib32/libcurl.so.3",
--#endif
-+ "libcurl-gnutls.so.3", // See above for Debian
-+#elif defined(XP_MACOSX)
- // macOS
- "libcurl.dylib",
- "libcurl.4.dylib",
-- "libcurl.3.dylib"
-+ "libcurl.3.dylib",
-+#endif
- };
-
-- for (const char* libname : libcurlNames) {
-- mLib = dlopen(libname, RTLD_NOW);
-+ // libcurl might show up under different names, try them all until we find it
-+
-+ for (const char* libpath : libcurlPaths) {
-+ for (const char* libname : libcurlNames) {
-+ string fullpath = string(libpath) + "/" + libname;
-+ mLib = dlopen(fullpath.c_str(), RTLD_NOW);
-+
-+ if (mLib) {
-+ break;
-+ }
-+ }
-
- if (mLib) {
- break;
diff --git a/www/firefox/files/patch-bug1401573 b/www/firefox/files/patch-bug1401573
deleted file mode 100644
index 22fc6f569a59..000000000000
--- a/www/firefox/files/patch-bug1401573
+++ /dev/null
@@ -1,27 +0,0 @@
-commit d0ed05261f20
-Author: jason laster <jlaster@mozilla.com>
-Date: Wed Sep 20 10:52:54 2017 -0400
-
- Bug 1401573 - Fix PoE, Link, and linux issue. r=nchevobbe
-
- MozReview-Commit-ID: 35TA6bhW1Wr
----
- devtools/client/debugger/new/debugger.js | 68 +++++++++++++++++-----
- devtools/client/debugger/new/panel.js | 27 ++++++++-
- .../new/test/mochitest/browser_dbg-expressions.js | 2 +-
- 3 files changed, 79 insertions(+), 18 deletions(-)
-
-diff --git devtools/client/debugger/new/debugger.js devtools/client/debugger/new/debugger.js
-index f52a3e380ab6..c1213180cb13 100644
---- devtools/client/debugger/new/debugger.js
-+++ devtools/client/debugger/new/debugger.js
-@@ -29493,7 +29493,8 @@ return /******/ (function(modules) { // webpackBootstr
- }
-
- function getKeyForOS(os, action) {
-- return KEYS[os][action];
-+ var osActions = KEYS[os] || KEYS.Linux;
-+ return osActions[action];
- }
-
- function formatKey(action) {
diff --git a/www/firefox/files/patch-bug1401804 b/www/firefox/files/patch-bug1401804
deleted file mode 100644
index c3b4688dc744..000000000000
--- a/www/firefox/files/patch-bug1401804
+++ /dev/null
@@ -1,31 +0,0 @@
-commit 38e6bb85066b
-Author: Jon Coppeard <jcoppeard@mozilla.com>
-Date: Fri Sep 22 13:09:44 2017 +0100
-
- Bug 1401804 - Fix IsMarkedBlack check used in gray marking asserts r=sfink a=sylvestre
----
- js/src/gc/Barrier.cpp | 11 ++---------
- 1 file changed, 2 insertions(+), 9 deletions(-)
-
-diff --git js/src/gc/Barrier.cpp js/src/gc/Barrier.cpp
-index 5a5dfbe9bed0..0c42d16e7117 100644
---- js/src/gc/Barrier.cpp
-+++ js/src/gc/Barrier.cpp
-@@ -33,15 +33,8 @@ RuntimeFromActiveCooperatingThreadIsHeapMajorCollecting(JS::shadow::Zone* shadow
- bool
- IsMarkedBlack(JSObject* obj)
- {
-- // Note: we assume conservatively that Nursery things will be live.
-- if (!obj->isTenured())
-- return true;
--
-- gc::TenuredCell& tenured = obj->asTenured();
-- if (tenured.isMarkedAny() || tenured.arena()->allocatedDuringIncremental)
-- return true;
--
-- return false;
-+ return obj->isMarkedBlack() ||
-+ (obj->isTenured() && obj->asTenured().arena()->allocatedDuringIncremental);
- }
-
- bool
diff --git a/www/firefox/files/patch-bug1402363 b/www/firefox/files/patch-bug1402363
deleted file mode 100644
index 49caa0265b4a..000000000000
--- a/www/firefox/files/patch-bug1402363
+++ /dev/null
@@ -1,199 +0,0 @@
-commit 3b1474dc71b8
-Author: Christoph Kerschbaumer <ckerschb@christophkerschbaumer.com>
-Date: Mon Oct 2 09:11:57 2017 +0200
-
- Bug 1402363 - Explicitly cancel channel after mixed content redirect. r=honza, r=kate, a=ritu
-
- --HG--
- extra : source : 2773796df8a337e5de31811acb4662ce67955f93
----
- dom/security/nsMixedContentBlocker.cpp | 7 ++++++-
- 1 file changed, 6 insertions(+), 1 deletion(-)
-
-diff --git dom/security/nsMixedContentBlocker.cpp dom/security/nsMixedContentBlocker.cpp
-index 46760e69cb91..28740da9efca 100644
---- dom/security/nsMixedContentBlocker.cpp
-+++ dom/security/nsMixedContentBlocker.cpp
-@@ -394,7 +394,11 @@ nsMixedContentBlocker::AsyncOnChannelRedirect(nsIChannel* aOldChannel,
- nullptr, // aExtra
- requestingPrincipal,
- &decision);
-- NS_ENSURE_SUCCESS(rv, rv);
-+ if (NS_FAILED(rv)) {
-+ autoCallback.DontCallback();
-+ aOldChannel->Cancel(NS_ERROR_DOM_BAD_URI);
-+ return NS_BINDING_FAILED;
-+ }
-
- if (nsMixedContentBlocker::sSendHSTSPriming) {
- // The LoadInfo passed in is for the original channel, HSTS priming needs to
-@@ -419,6 +423,7 @@ nsMixedContentBlocker::AsyncOnChannelRedirect(nsIChannel* aOldChannel,
- // If the channel is about to load mixed content, abort the channel
- if (!NS_CP_ACCEPTED(decision)) {
- autoCallback.DontCallback();
-+ aOldChannel->Cancel(NS_ERROR_DOM_BAD_URI);
- return NS_BINDING_FAILED;
- }
-
-
-commit a709f413ebbd (tag: FIREFOX_57_0b5_RELEASE, tag: FIREFOX_57_0b5_BUILD1)
-Author: Christoph Kerschbaumer <ckerschb@christophkerschbaumer.com>
-Date: Mon Oct 2 09:12:12 2017 +0200
-
- Bug 1402363 - Test Mixed Content Redirect Blocking. r=tanvi, r=kate, a=ritu
-
- --HG--
- extra : source : fcefba24074f60e2d3296996e20a8dd8bc6bebe0
----
- .../test/mixedcontentblocker/file_redirect.html | 31 ++++++++++++++
- .../mixedcontentblocker/file_redirect_handler.sjs | 29 +++++++++++++
- .../test/mixedcontentblocker/mochitest.ini | 3 ++
- .../test/mixedcontentblocker/test_redirect.html | 50 ++++++++++++++++++++++
- 4 files changed, 113 insertions(+)
-
-diff --git dom/security/test/mixedcontentblocker/file_redirect.html dom/security/test/mixedcontentblocker/file_redirect.html
-new file mode 100644
-index 000000000000..99e187379139
---- /dev/null
-+++ dom/security/test/mixedcontentblocker/file_redirect.html
-@@ -0,0 +1,31 @@
-+<!DOCTYPE HTML>
-+<html>
-+<head>
-+ <title>Bug1402363: Test mixed content redirects</title>
-+</head>
-+<body>
-+
-+<script type="text/javascript">
-+ const PATH = "https://example.com/tests/dom/security/test/mixedcontentblocker/";
-+
-+ // check a fetch redirect from https to https (should be allowed)
-+ fetch(PATH + "file_redirect_handler.sjs?https-to-https-redirect", {
-+ method: 'get'
-+ }).then(function(response) {
-+ window.parent.postMessage("https-to-https-loaded", "*");
-+ }).catch(function(err) {
-+ window.parent.postMessage("https-to-https-blocked", "*");
-+ });
-+
-+ // check a fetch redirect from https to http (should be blocked)
-+ fetch(PATH + "file_redirect_handler.sjs?https-to-http-redirect", {
-+ method: 'get'
-+ }).then(function(response) {
-+ window.parent.postMessage("https-to-http-loaded", "*");
-+ }).catch(function(err) {
-+ window.parent.postMessage("https-to-http-blocked", "*");
-+ });
-+
-+</script>
-+</body>
-+</html>
-diff --git dom/security/test/mixedcontentblocker/file_redirect_handler.sjs dom/security/test/mixedcontentblocker/file_redirect_handler.sjs
-new file mode 100644
-index 000000000000..88dc849fe9a7
---- /dev/null
-+++ dom/security/test/mixedcontentblocker/file_redirect_handler.sjs
-@@ -0,0 +1,29 @@
-+// custom *.sjs file for
-+// Bug 1402363: Test Mixed Content Redirect Blocking.
-+
-+const URL_PATH = "example.com/tests/dom/security/test/mixedcontentblocker/";
-+
-+function handleRequest(request, response) {
-+ response.setHeader("Cache-Control", "no-cache", false);
-+ let queryStr = request.queryString;
-+
-+ if (queryStr === "https-to-https-redirect") {
-+ response.setStatusLine("1.1", 302, "Found");
-+ response.setHeader("Location",
-+ "https://" + URL_PATH + "file_redirect_handler.sjs?load", false);
-+ return;
-+ }
-+
-+ if (queryStr === "https-to-http-redirect") {
-+ response.setStatusLine("1.1", 302, "Found");
-+ response.setHeader("Location",
-+ "http://" + URL_PATH + "file_redirect_handler.sjs?load", false);
-+ return;
-+ }
-+
-+ if (queryStr === "load") {
-+ response.setHeader("Content-Type", "text/html", false);
-+ response.write("foo");
-+ return;
-+ }
-+}
-diff --git dom/security/test/mixedcontentblocker/mochitest.ini dom/security/test/mixedcontentblocker/mochitest.ini
-index 7eed89effbce..9daf1f0ae73b 100644
---- dom/security/test/mixedcontentblocker/mochitest.ini
-+++ dom/security/test/mixedcontentblocker/mochitest.ini
-@@ -14,6 +14,8 @@ support-files =
- file_server.sjs
- !/dom/media/test/320x240.ogv
- !/image/test/mochitest/blue.png
-+ file_redirect.html
-+ file_redirect_handler.sjs
-
- [test_main.html]
- skip-if = toolkit == 'android' #TIMED_OUT
-@@ -21,3 +23,4 @@ skip-if = toolkit == 'android' #TIMED_OUT
- skip-if = toolkit == 'android' || (os=='linux' && bits==32) #Android: TIMED_OUT; Linux32:bug 1324870
- [test_frameNavigation.html]
- skip-if = toolkit == 'android' #TIMED_OUT
-+[test_redirect.html]
-diff --git dom/security/test/mixedcontentblocker/test_redirect.html dom/security/test/mixedcontentblocker/test_redirect.html
-new file mode 100644
-index 000000000000..f4aeef3d9895
---- /dev/null
-+++ dom/security/test/mixedcontentblocker/test_redirect.html
-@@ -0,0 +1,50 @@
-+<!DOCTYPE HTML>
-+<html>
-+<head>
-+ <title>Bug1402363: Test mixed content redirects</title>
-+ <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
-+ <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
-+</head>
-+
-+<body onload='startTest()'>
-+<iframe style="width:100%;height:300px;" id="testframe"></iframe>
-+
-+<script class="testbody" type="text/javascript">
-+
-+SimpleTest.waitForExplicitFinish();
-+
-+const PATH = "https://example.com/tests/dom/security/test/mixedcontentblocker/";
-+let testcounter = 0;
-+
-+window.addEventListener("message", receiveMessage);
-+function receiveMessage(event) {
-+ if (event.data === "https-to-https-loaded") {
-+ ok(true, "https to https fetch redirect should be allowed");
-+ }
-+ else if (event.data === "https-to-http-blocked") {
-+ ok(true, "https to http fetch redirect should be blocked");
-+ }
-+ else {
-+ ok(false, "sanity: we should never enter that branch (" + event.data + ")");
-+ }
-+ testcounter++;
-+ if (testcounter < 2) {
-+ return;
-+ }
-+ window.removeEventListener("message", receiveMessage);
-+ SimpleTest.finish();
-+}
-+
-+function startTest() {
-+ SpecialPowers.pushPrefEnv({
-+ 'set': [["security.mixed_content.use_hsts", false],
-+ ["security.mixed_content.send_hsts_priming", false]]
-+ }, function () {
-+ let testframe = document.getElementById("testframe");
-+ testframe.src = PATH + "file_redirect.html";
-+ });
-+}
-+
-+</script>
-+</body>
-+</html>
diff --git a/www/firefox/files/patch-bug1402442 b/www/firefox/files/patch-bug1402442
deleted file mode 100644
index 18bf1c88ca47..000000000000
--- a/www/firefox/files/patch-bug1402442
+++ /dev/null
@@ -1,181 +0,0 @@
-commit 44b4458e2d21
-Author: Emilio Cobos Álvarez <emilio@crisal.io>
-Date: Mon Sep 25 18:25:29 2017 +0200
-
- Bug 1402442 - Properly remove display: contents pseudo-frames. r=mats, a=ritu
-
- MozReview-Commit-ID: 4pjVLQfv3YR
- Signed-off-by: Emilio Cobos Álvarez <emilio@crisal.io>
-
- --HG--
- extra : source : faa69ac1c14b79838cc0aac842b470a110542ebd
- extra : amend_source : 3a76e0123bf3f7d10295000cc44fd8bdddf700df
----
- layout/base/nsCSSFrameConstructor.cpp | 26 +++++++++++++++-------
- testing/web-platform/meta/MANIFEST.json | 25 +++++++++++++++++++++
- ...dynamic-generated-content-fieldset-001.html.ini | 4 ++++
- ...dynamic-generated-content-fieldset-001-ref.html | 16 +++++++++++++
- ...nts-dynamic-generated-content-fieldset-001.html | 26 ++++++++++++++++++++++
- 5 files changed, 89 insertions(+), 8 deletions(-)
-
-diff --git layout/base/nsCSSFrameConstructor.cpp layout/base/nsCSSFrameConstructor.cpp
-index 99b1211b399b..4fce3fb381a7 100644
---- layout/base/nsCSSFrameConstructor.cpp
-+++ layout/base/nsCSSFrameConstructor.cpp
-@@ -1698,6 +1698,17 @@ nsCSSFrameConstructor::NotifyDestroyingFrame(nsIFrame* aFrame)
- nsFrameManager::NotifyDestroyingFrame(aFrame);
- }
-
-+static bool
-+HasGeneratedContent(const nsIContent* aChild)
-+{
-+ if (!aChild->MayHaveAnonymousChildren()) {
-+ return false;
-+ }
-+
-+ return nsLayoutUtils::GetBeforeFrame(aChild) ||
-+ nsLayoutUtils::GetAfterFrame(aChild);
-+}
-+
- struct nsGenConInitializer {
- nsAutoPtr<nsGenConNode> mNode;
- nsGenConList* mList;
-@@ -8642,16 +8653,15 @@ nsCSSFrameConstructor::ContentRemoved(nsIContent* aCo
- MOZ_ASSERT(!childFrame || !GetDisplayContentsStyleFor(aChild),
- "display:contents nodes shouldn't have a frame");
- if (!childFrame && GetDisplayContentsStyleFor(aChild)) {
-- nsIContent* ancestor = aContainer;
-- MOZ_ASSERT(ancestor, "display: contents on the root?");
-- while (!ancestor->GetPrimaryFrame()) {
-- // FIXME(emilio): Should this use the flattened tree parent instead?
-- ancestor = ancestor->GetParent();
-- MOZ_ASSERT(ancestor, "we can't have a display: contents subtree root!");
-- }
-+ if (HasGeneratedContent(aChild)) {
-+ nsIContent* ancestor = aContainer;
-+ MOZ_ASSERT(ancestor, "display: contents on the root?");
-+ while (!ancestor->GetPrimaryFrame()) {
-+ // FIXME(emilio): Should this use the flattened tree parent instead?
-+ ancestor = ancestor->GetParent();
-+ MOZ_ASSERT(ancestor, "we can't have a display: contents subtree root!");
-+ }
-
-- nsIFrame* ancestorFrame = ancestor->GetPrimaryFrame();
-- if (ancestorFrame->GetProperty(nsIFrame::GenConProperty())) {
- *aDidReconstruct = true;
- LAYOUT_PHASE_TEMP_EXIT();
-
-diff --git testing/web-platform/meta/MANIFEST.json testing/web-platform/meta/MANIFEST.json
-index 5f05321c5a70..8aed4a4b5078 100644
---- testing/web-platform/meta/MANIFEST.json
-+++ testing/web-platform/meta/MANIFEST.json
-@@ -102975,6 +102975,18 @@
- {}
- ]
- ],
-+ "css/css-display-3/display-contents-dynamic-generated-content-fieldset-001.html": [
-+ [
-+ "/css/css-display-3/display-contents-dynamic-generated-content-fieldset-001.html",
-+ [
-+ [
-+ "/css/css-display-3/display-contents-dynamic-generated-content-fieldset-001-ref.html",
-+ "=="
-+ ]
-+ ],
-+ {}
-+ ]
-+ ],
- "css/css-display-3/display-contents-dynamic-inline-flex-001-inline.html": [
- [
- "/css/css-display-3/display-contents-dynamic-inline-flex-001-inline.html",
-@@ -227658,6 +227670,11 @@
- {}
- ]
- ],
-+ "css/css-display-3/display-contents-dynamic-generated-content-fieldset-001-ref.html": [
-+ [
-+ {}
-+ ]
-+ ],
- "css/css-display-3/display-contents-flex-001-ref.html": [
- [
- {}
-@@ -502880,6 +502897,14 @@
- "a2d7c9368ed8c01ca06c36646666270e85aee070",
- "reftest"
- ],
-+ "css/css-display-3/display-contents-dynamic-generated-content-fieldset-001-ref.html": [
-+ "30ec5c8ddacfbfef8434c37ca7a0a766f2bbc89a",
-+ "support"
-+ ],
-+ "css/css-display-3/display-contents-dynamic-generated-content-fieldset-001.html": [
-+ "984bebb3c3b8661aedef4a229848dfa818bb1f4a",
-+ "reftest"
-+ ],
- "css/css-display-3/display-contents-dynamic-inline-flex-001-inline.html": [
- "40fb07e8ada1530e6835ff2d4e49c5571ffb0baa",
- "reftest"
-diff --git testing/web-platform/meta/css/css-display-3/display-contents-dynamic-generated-content-fieldset-001.html.ini testing/web-platform/meta/css/css-display-3/display-contents-dynamic-generated-content-fieldset-001.html.ini
-new file mode 100644
-index 000000000000..63c7442a2362
---- /dev/null
-+++ testing/web-platform/meta/css/css-display-3/display-contents-dynamic-generated-content-fieldset-001.html.ini
-@@ -0,0 +1,4 @@
-+[display-contents-dynamic-generated-content-fieldset-001.html]
-+ type: reftest
-+ expected:
-+ if not stylo: FAIL
-diff --git testing/web-platform/tests/css/css-display-3/display-contents-dynamic-generated-content-fieldset-001-ref.html testing/web-platform/tests/css/css-display-3/display-contents-dynamic-generated-content-fieldset-001-ref.html
-new file mode 100644
-index 000000000000..651bc19b83e9
---- /dev/null
-+++ testing/web-platform/tests/css/css-display-3/display-contents-dynamic-generated-content-fieldset-001-ref.html
-@@ -0,0 +1,16 @@
-+<!doctype html>
-+<meta charset="utf-8">
-+<title>CSS Reftest Reference</title>
-+<link rel="author" title="Emilio Cobos Álvarez" href="mailto:emilio@crisal.io">
-+<style>
-+div {
-+ display: contents;
-+ border: 10px solid red;
-+}
-+</style>
-+<p>
-+ Test passes if there is no red text and no red border.
-+</p>
-+<fieldset>
-+ <div></div>
-+</fieldset>
-diff --git testing/web-platform/tests/css/css-display-3/display-contents-dynamic-generated-content-fieldset-001.html testing/web-platform/tests/css/css-display-3/display-contents-dynamic-generated-content-fieldset-001.html
-new file mode 100644
-index 000000000000..8f8a0ba47971
---- /dev/null
-+++ testing/web-platform/tests/css/css-display-3/display-contents-dynamic-generated-content-fieldset-001.html
-@@ -0,0 +1,26 @@
-+<!doctype html>
-+<meta charset="utf-8">
-+<title>CSS Test: Dynamic changes to display: contents generated content in fieldsets.</title>
-+<link rel="author" title="Emilio Cobos Álvarez" href="mailto:emilio@crisal.io">
-+<link rel="help" href="https://drafts.csswg.org/css-display-3/#valdef-display-contents">
-+<link rel="match" href="display-contents-dynamic-generated-content-fieldset-001-ref.html">
-+<style>
-+.after::after {
-+ content: "FAIL";
-+ color: red;
-+}
-+div {
-+ display: contents;
-+ border: 10px solid red;
-+}
-+</style>
-+<p>
-+ Test passes if there is no red text and no red border.
-+</p>
-+<fieldset>
-+ <div class="after"></div>
-+</fieldset>
-+<script>
-+document.body.offsetHeight;
-+document.querySelector("div").classList.remove("after");
-+</script>
diff --git a/www/firefox/files/patch-bug1402876 b/www/firefox/files/patch-bug1402876
deleted file mode 100644
index a7886d0910f3..000000000000
--- a/www/firefox/files/patch-bug1402876
+++ /dev/null
@@ -1,66 +0,0 @@
-commit 434da479b6e1
-Author: Jan de Mooij <jdemooij@mozilla.com>
-Date: Wed Sep 27 14:43:36 2017 +0200
-
- Bug 1402876 - Remove unnecessary InvalidateCompilerOutputsForScript call. r=nbp, a=sledru
-
- --HG--
- extra : source : c1a158ca2b1cfc009cd1545538cacbc4feabc48b
----
- js/src/jit/Ion.cpp | 3 ---
- js/src/vm/TypeInference.cpp | 12 ------------
- js/src/vm/TypeInference.h | 4 ----
- 3 files changed, 19 deletions(-)
-
-diff --git js/src/jit/Ion.cpp js/src/jit/Ion.cpp
-index ba583fe12297..f205b83d2893 100644
---- js/src/jit/Ion.cpp
-+++ js/src/jit/Ion.cpp
-@@ -574,9 +574,6 @@ jit::LinkIonScript(JSContext* cx, HandleScript calleeScript)
- // doesn't has code to handle it after linking happened. So it's
- // not OK to throw a catchable exception from there.
- cx->clearPendingException();
--
-- // Reset the TypeZone's compiler output for this script, if any.
-- InvalidateCompilerOutputsForScript(cx, calleeScript);
- }
- }
-
-diff --git js/src/vm/TypeInference.cpp js/src/vm/TypeInference.cpp
-index de98bb654fa8..70d6dfc19d20 100644
---- js/src/vm/TypeInference.cpp
-+++ js/src/vm/TypeInference.cpp
-@@ -1511,18 +1511,6 @@ js::FinishCompilation(JSContext* cx, HandleScript script, CompilerConstraintList
- return true;
- }
-
--void
--js::InvalidateCompilerOutputsForScript(JSContext* cx, HandleScript script)
--{
-- TypeZone& types = cx->zone()->types;
-- if (types.compilerOutputs) {
-- for (auto& co : *types.compilerOutputs) {
-- if (co.script() == script)
-- co.invalidate();
-- }
-- }
--}
--
- static void
- CheckDefinitePropertiesTypeSet(JSContext* cx, TemporaryTypeSet* frozen, StackTypeSet* actual)
- {
-diff --git js/src/vm/TypeInference.h js/src/vm/TypeInference.h
-index df2d496ca879..318c3e813b1a 100644
---- js/src/vm/TypeInference.h
-+++ js/src/vm/TypeInference.h
-@@ -1299,10 +1299,6 @@ bool
- FinishCompilation(JSContext* cx, HandleScript script, CompilerConstraintList* constraints,
- RecompileInfo* precompileInfo, bool* isValidOut);
-
--// Reset any CompilerOutput present for a script.
--void
--InvalidateCompilerOutputsForScript(JSContext* cx, HandleScript script);
--
- // Update the actual types in any scripts queried by constraints with any
- // speculative types added during the definite properties analysis.
- void
diff --git a/www/firefox/files/patch-bug1402896 b/www/firefox/files/patch-bug1402896
deleted file mode 100644
index eacff0bd407a..000000000000
--- a/www/firefox/files/patch-bug1402896
+++ /dev/null
@@ -1,40 +0,0 @@
-commit 6bf098b436b0
-Author: Gijs Kruitbosch <gijskruitbosch@gmail.com>
-Date: Mon Sep 25 17:24:26 2017 +0100
-
- Bug 1402896 - Make the url bar strip javascript even when preceded by control characters. r=mak, a=sledru
-
- MozReview-Commit-ID: 5ZO8n5lfvnl
-
- --HG--
- extra : source : 638e145f6bba437642d55f7b2baf5458df61419a
----
- browser/base/content/browser.js | 2 +-
- .../content/test/urlbar/browser_removeUnsafeProtocolsFromURLBarPaste.js | 1 +
- 2 files changed, 2 insertions(+), 1 deletion(-)
-
-diff --git browser/base/content/browser.js browser/base/content/browser.js
-index 8b0fb0276d19..b73ab2a3dd7e 100755
---- browser/base/content/browser.js
-+++ browser/base/content/browser.js
-@@ -6128,7 +6128,7 @@ function stripUnsafeProtocolOnPaste(pasteData) {
- // LOAD_FLAGS_DISALLOW_INHERIT_PRINCIPAL for those.
- let changed = false;
- let pasteDataNoJS = pasteData.replace(/\r?\n/g, "")
-- .replace(/^(?:\s*javascript:)+/i,
-+ .replace(/^(?:\W*javascript:)+/i,
- () => {
- changed = true;
- return "";
-diff --git browser/base/content/test/urlbar/browser_removeUnsafeProtocolsFromURLBarPaste.js browser/base/content/test/urlbar/browser_removeUnsafeProtocolsFromURLBarPaste.js
-index 6f6682d51688..27129297b0a3 100644
---- browser/base/content/test/urlbar/browser_removeUnsafeProtocolsFromURLBarPaste.js
-+++ browser/base/content/test/urlbar/browser_removeUnsafeProtocolsFromURLBarPaste.js
-@@ -7,6 +7,7 @@ var pairs = [
- ["javascript:", ""],
- ["javascript:1+1", "1+1"],
- ["javascript:document.domain", "document.domain"],
-+ [" \u0001\u0002\u0003\u0004\u0005\u0006\u0007\u0008\u0009javascript:document.domain", "document.domain"],
- ["java\nscript:foo", "foo"],
- ["http://\nexample.com", "http://example.com"],
- ["http://\nexample.com\n", "http://example.com"],
diff --git a/www/firefox/files/patch-bug1402966 b/www/firefox/files/patch-bug1402966
deleted file mode 100644
index 51123f684a06..000000000000
--- a/www/firefox/files/patch-bug1402966
+++ /dev/null
@@ -1,51 +0,0 @@
-commit 6149574dc0f9
-Author: Gabriele Svelto <gsvelto@mozilla.com>
-Date: Tue Sep 26 09:35:03 2017 +0200
-
- Bug 1402966 - Search for libcurl in more paths to support various *BSDs. r=Dexter, a=sledru
-
- MozReview-Commit-ID: J4ykuSVEa0y
-
- --HG--
- extra : source : 4741b93cfdf29517ff8eae863825fdc2ab5bd7bd
----
- .../telemetry/pingsender/pingsender_unix_common.cpp | 16 ++++++++++------
- 1 file changed, 10 insertions(+), 6 deletions(-)
-
-diff --git toolkit/components/telemetry/pingsender/pingsender_unix_common.cpp toolkit/components/telemetry/pingsender/pingsender_unix_common.cpp
-index ae20f4114193..7817e93e3d1f 100644
---- toolkit/components/telemetry/pingsender/pingsender_unix_common.cpp
-+++ toolkit/components/telemetry/pingsender/pingsender_unix_common.cpp
-@@ -88,10 +88,19 @@ CurlWrapper::Init()
- "/usr/lib/i386-linux-gnu", // Debian 32-bit x86
- "/usr/lib/x86_64-linux-gnu", // Debian 64-bit x86
- #endif // XP_LINUX
-+#if !defined(XP_MACOSX) && !defined(XP_LINUX) // Various BSDs
-+ "/usr/local/lib", // FreeBSD, OpenBSD
-+ "/usr/pkg/lib", // NetBSD
-+#endif // !defined(XP_MACOSX) && !defined(XP_LINUX)
- };
-
- const char* libcurlNames[] = {
--#ifdef XP_LINUX
-+#if defined(XP_MACOSX)
-+ // macOS
-+ "libcurl.dylib",
-+ "libcurl.4.dylib",
-+ "libcurl.3.dylib",
-+#else // Linux, *BSD, ...
- "libcurl.so",
- "libcurl.so.4",
- // Debian gives libcurl a different name when it is built against GnuTLS
-@@ -100,11 +109,6 @@ CurlWrapper::Init()
- // Older versions in case we find nothing better
- "libcurl.so.3",
- "libcurl-gnutls.so.3", // See above for Debian
--#elif defined(XP_MACOSX)
-- // macOS
-- "libcurl.dylib",
-- "libcurl.4.dylib",
-- "libcurl.3.dylib",
- #endif
- };
-
diff --git a/www/firefox/files/patch-bug1403646 b/www/firefox/files/patch-bug1403646
deleted file mode 100644
index 225d4139f356..000000000000
--- a/www/firefox/files/patch-bug1403646
+++ /dev/null
@@ -1,392 +0,0 @@
-commit 474ae0592f23
-Author: Boris Zbarsky <bzbarsky@mit.edu>
-Date: Thu Sep 28 22:05:43 2017 -0400
-
- Bug 1403646 - Make sure dead object proxies have the same background-finalization status as the wrapper they replace. r=jonco, a=sledru
-
- MozReview-Commit-ID: GTKbR0azcRy
-
- --HG--
- extra : source : 296e1b4704deb1c6b3f9a6f5fc56688e89c01117
----
- js/src/proxy/DeadObjectProxy.cpp | 204 +++++++++++++++++++++++++++------------
- js/src/proxy/DeadObjectProxy.h | 13 ++-
- 2 files changed, 156 insertions(+), 61 deletions(-)
-
-diff --git js/src/proxy/DeadObjectProxy.cpp js/src/proxy/DeadObjectProxy.cpp
-index 3bd7a405c002..658880a07616 100644
---- js/src/proxy/DeadObjectProxy.cpp
-+++ js/src/proxy/DeadObjectProxy.cpp
-@@ -20,73 +20,81 @@ ReportDead(JSContext *cx)
- JS_ReportErrorNumberASCII(cx, GetErrorMessage, nullptr, JSMSG_DEAD_OBJECT);
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- bool
--DeadObjectProxy<CC>::getOwnPropertyDescriptor(JSContext* cx, HandleObject wrapper, HandleId id,
-- MutableHandle<PropertyDescriptor> desc) const
-+DeadObjectProxy<CC, BF>::getOwnPropertyDescriptor(JSContext* cx, HandleObject wrapper, HandleId id,
-+ MutableHandle<PropertyDescriptor> desc) const
- {
- ReportDead(cx);
- return false;
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- bool
--DeadObjectProxy<CC>::defineProperty(JSContext* cx, HandleObject wrapper, HandleId id,
-- Handle<PropertyDescriptor> desc,
-- ObjectOpResult& result) const
-+DeadObjectProxy<CC, BF>::defineProperty(JSContext* cx, HandleObject wrapper, HandleId id,
-+ Handle<PropertyDescriptor> desc,
-+ ObjectOpResult& result) const
- {
- ReportDead(cx);
- return false;
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- bool
--DeadObjectProxy<CC>::ownPropertyKeys(JSContext* cx, HandleObject wrapper,
-- AutoIdVector& props) const
-+DeadObjectProxy<CC, BF>::ownPropertyKeys(JSContext* cx, HandleObject wrapper,
-+ AutoIdVector& props) const
- {
- ReportDead(cx);
- return false;
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- bool
--DeadObjectProxy<CC>::delete_(JSContext* cx, HandleObject wrapper, HandleId id,
-- ObjectOpResult& result) const
-+DeadObjectProxy<CC, BF>::delete_(JSContext* cx, HandleObject wrapper, HandleId id,
-+ ObjectOpResult& result) const
- {
- ReportDead(cx);
- return false;
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- bool
--DeadObjectProxy<CC>::getPrototype(JSContext* cx, HandleObject proxy,
-- MutableHandleObject protop) const
-+DeadObjectProxy<CC, BF>::getPrototype(JSContext* cx, HandleObject proxy,
-+ MutableHandleObject protop) const
- {
- protop.set(nullptr);
- return true;
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- bool
--DeadObjectProxy<CC>::getPrototypeIfOrdinary(JSContext* cx, HandleObject proxy, bool* isOrdinary,
-- MutableHandleObject protop) const
-+DeadObjectProxy<CC, BF>::getPrototypeIfOrdinary(JSContext* cx, HandleObject proxy, bool* isOrdinary,
-+ MutableHandleObject protop) const
- {
- *isOrdinary = false;
- return true;
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- bool
--DeadObjectProxy<CC>::preventExtensions(JSContext* cx, HandleObject proxy,
-- ObjectOpResult& result) const
-+DeadObjectProxy<CC, BF>::preventExtensions(JSContext* cx, HandleObject proxy,
-+ ObjectOpResult& result) const
- {
- ReportDead(cx);
- return false;
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- bool
--DeadObjectProxy<CC>::isExtensible(JSContext* cx, HandleObject proxy, bool* extensible) const
-+DeadObjectProxy<CC, BF>::isExtensible(JSContext* cx, HandleObject proxy, bool* extensible) const
- {
- // This is kind of meaningless, but dead-object semantics aside,
- // [[Extensible]] always being true is consistent with other proxy types.
-@@ -94,95 +102,141 @@ DeadObjectProxy<CC>::isExtensible(JSContext* cx, HandleObject proxy, bool* exten
- return true;
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- bool
--DeadObjectProxy<CC>::call(JSContext* cx, HandleObject wrapper, const CallArgs& args) const
-+DeadObjectProxy<CC, BF>::call(JSContext* cx, HandleObject wrapper, const CallArgs& args) const
- {
- ReportDead(cx);
- return false;
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- bool
--DeadObjectProxy<CC>::construct(JSContext* cx, HandleObject wrapper, const CallArgs& args) const
-+DeadObjectProxy<CC, BF>::construct(JSContext* cx, HandleObject wrapper, const CallArgs& args) const
- {
- ReportDead(cx);
- return false;
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- bool
--DeadObjectProxy<CC>::nativeCall(JSContext* cx, IsAcceptableThis test, NativeImpl impl,
-- const CallArgs& args) const
-+DeadObjectProxy<CC, BF>::nativeCall(JSContext* cx, IsAcceptableThis test, NativeImpl impl,
-+ const CallArgs& args) const
- {
- ReportDead(cx);
- return false;
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- bool
--DeadObjectProxy<CC>::hasInstance(JSContext* cx, HandleObject proxy, MutableHandleValue v,
-- bool* bp) const
-+DeadObjectProxy<CC, BF>::hasInstance(JSContext* cx, HandleObject proxy, MutableHandleValue v,
-+ bool* bp) const
- {
- ReportDead(cx);
- return false;
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- bool
--DeadObjectProxy<CC>::getBuiltinClass(JSContext* cx, HandleObject proxy, ESClass* cls) const
-+DeadObjectProxy<CC, BF>::getBuiltinClass(JSContext* cx, HandleObject proxy, ESClass* cls) const
- {
- ReportDead(cx);
- return false;
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- bool
--DeadObjectProxy<CC>::isArray(JSContext* cx, HandleObject obj, JS::IsArrayAnswer* answer) const
-+DeadObjectProxy<CC, BF>::isArray(JSContext* cx, HandleObject obj, JS::IsArrayAnswer* answer) const
- {
- ReportDead(cx);
- return false;
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- const char*
--DeadObjectProxy<CC>::className(JSContext* cx, HandleObject wrapper) const
-+DeadObjectProxy<CC, BF>::className(JSContext* cx, HandleObject wrapper) const
- {
- return "DeadObject";
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- JSString*
--DeadObjectProxy<CC>::fun_toString(JSContext* cx, HandleObject proxy, bool isToSource) const
-+DeadObjectProxy<CC, BF>::fun_toString(JSContext* cx, HandleObject proxy, bool isToSource) const
- {
- ReportDead(cx);
- return nullptr;
- }
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BF>
- RegExpShared*
--DeadObjectProxy<CC>::regexp_toShared(JSContext* cx, HandleObject proxy) const
-+DeadObjectProxy<CC, BF>::regexp_toShared(JSContext* cx, HandleObject proxy) const
- {
- ReportDead(cx);
- return nullptr;
- }
-
- template <>
--const char DeadObjectProxy<DeadProxyNotCallableNotConstructor>::family = 0;
-+const char DeadObjectProxy<DeadProxyNotCallableNotConstructor,
-+ DeadProxyBackgroundFinalized::Yes>::family = 0;
- template <>
--const char DeadObjectProxy<DeadProxyNotCallableIsConstructor>::family = 0;
-+const char DeadObjectProxy<DeadProxyNotCallableNotConstructor,
-+ DeadProxyBackgroundFinalized::No>::family = 0;
- template <>
--const char DeadObjectProxy<DeadProxyIsCallableNotConstructor>::family = 0;
-+const char DeadObjectProxy<DeadProxyNotCallableIsConstructor,
-+ DeadProxyBackgroundFinalized::Yes>::family = 0;
- template <>
--const char DeadObjectProxy<DeadProxyIsCallableIsConstructor>::family = 0;
-+const char DeadObjectProxy<DeadProxyNotCallableIsConstructor,
-+ DeadProxyBackgroundFinalized::No>::family = 0;
-+template <>
-+const char DeadObjectProxy<DeadProxyIsCallableNotConstructor,
-+ DeadProxyBackgroundFinalized::Yes>::family = 0;
-+template <>
-+const char DeadObjectProxy<DeadProxyIsCallableNotConstructor,
-+ DeadProxyBackgroundFinalized::No>::family = 0;
-+template <>
-+const char DeadObjectProxy<DeadProxyIsCallableIsConstructor,
-+ DeadProxyBackgroundFinalized::Yes>::family = 0;
-+template <>
-+const char DeadObjectProxy<DeadProxyIsCallableIsConstructor,
-+ DeadProxyBackgroundFinalized::No>::family = 0;
-
- bool
- js::IsDeadProxyObject(JSObject* obj)
- {
-- return IsDerivedProxyObject(obj, DeadObjectProxy<DeadProxyNotCallableNotConstructor>::singleton()) ||
-- IsDerivedProxyObject(obj, DeadObjectProxy<DeadProxyIsCallableIsConstructor>::singleton()) ||
-- IsDerivedProxyObject(obj, DeadObjectProxy<DeadProxyIsCallableNotConstructor>::singleton()) ||
-- IsDerivedProxyObject(obj, DeadObjectProxy<DeadProxyNotCallableIsConstructor>::singleton());
-+ return
-+ IsDerivedProxyObject(obj,
-+ DeadObjectProxy<DeadProxyNotCallableNotConstructor,
-+ DeadProxyBackgroundFinalized::Yes>::singleton()) ||
-+ IsDerivedProxyObject(obj,
-+ DeadObjectProxy<DeadProxyNotCallableNotConstructor,
-+ DeadProxyBackgroundFinalized::No>::singleton()) ||
-+ IsDerivedProxyObject(obj,
-+ DeadObjectProxy<DeadProxyIsCallableIsConstructor,
-+ DeadProxyBackgroundFinalized::Yes>::singleton()) ||
-+ IsDerivedProxyObject(obj,
-+ DeadObjectProxy<DeadProxyIsCallableIsConstructor,
-+ DeadProxyBackgroundFinalized::No>::singleton()) ||
-+ IsDerivedProxyObject(obj,
-+ DeadObjectProxy<DeadProxyIsCallableNotConstructor,
-+ DeadProxyBackgroundFinalized::Yes>::singleton()) ||
-+ IsDerivedProxyObject(obj,
-+ DeadObjectProxy<DeadProxyIsCallableNotConstructor,
-+ DeadProxyBackgroundFinalized::No>::singleton()) ||
-+ IsDerivedProxyObject(obj,
-+ DeadObjectProxy<DeadProxyNotCallableIsConstructor,
-+ DeadProxyBackgroundFinalized::Yes>::singleton()) ||
-+ IsDerivedProxyObject(obj,
-+ DeadObjectProxy<DeadProxyNotCallableIsConstructor,
-+ DeadProxyBackgroundFinalized::No>::singleton());
- }
-
-
-@@ -190,19 +244,48 @@ const BaseProxyHandler*
- js::SelectDeadProxyHandler(ProxyObject* obj)
- {
- // When nuking scripted proxies, isCallable and isConstructor values for
-- // the proxy needs to be preserved.
-+ // the proxy needs to be preserved. So does background-finalization status.
- uint32_t callable = obj->handler()->isCallable(obj);
- uint32_t constructor = obj->handler()->isConstructor(obj);
-+ bool finalizeInBackground = obj->handler()->finalizeInBackground(obj->private_());
-
- if (callable) {
-- if (constructor)
-- return DeadObjectProxy<DeadProxyIsCallableIsConstructor>::singleton();
-- return DeadObjectProxy<DeadProxyIsCallableNotConstructor>::singleton();
-+ if (constructor) {
-+ if (finalizeInBackground) {
-+ return DeadObjectProxy<DeadProxyIsCallableIsConstructor,
-+ DeadProxyBackgroundFinalized::Yes>::singleton();
-+ } else {
-+ return DeadObjectProxy<DeadProxyIsCallableIsConstructor,
-+ DeadProxyBackgroundFinalized::No>::singleton();
-+ }
-+ }
-+
-+ if (finalizeInBackground) {
-+ return DeadObjectProxy<DeadProxyIsCallableNotConstructor,
-+ DeadProxyBackgroundFinalized::Yes>::singleton();
-+ }
-+
-+ return DeadObjectProxy<DeadProxyIsCallableNotConstructor,
-+ DeadProxyBackgroundFinalized::No>::singleton();
-+ }
-+
-+ if (constructor) {
-+ if (finalizeInBackground) {
-+ return DeadObjectProxy<DeadProxyNotCallableIsConstructor,
-+ DeadProxyBackgroundFinalized::Yes>::singleton();
-+ }
-+
-+ return DeadObjectProxy<DeadProxyNotCallableIsConstructor,
-+ DeadProxyBackgroundFinalized::No>::singleton();
-+ }
-+
-+ if (finalizeInBackground) {
-+ return DeadObjectProxy<DeadProxyNotCallableNotConstructor,
-+ DeadProxyBackgroundFinalized::Yes>::singleton();
- }
-
-- if (constructor)
-- return DeadObjectProxy<DeadProxyNotCallableIsConstructor>::singleton();
-- return DeadObjectProxy<DeadProxyNotCallableNotConstructor>::singleton();
-+ return DeadObjectProxy<DeadProxyNotCallableNotConstructor,
-+ DeadProxyBackgroundFinalized::No>::singleton();
- }
-
- JSObject*
-@@ -214,7 +297,8 @@ js::NewDeadProxyObject(JSContext* cx, JSObject* origObj)
- if (origObj && origObj->is<ProxyObject>())
- handler = SelectDeadProxyHandler(&origObj->as<ProxyObject>());
- else
-- handler = DeadObjectProxy<DeadProxyNotCallableNotConstructor>::singleton();
-+ handler = DeadObjectProxy<DeadProxyNotCallableNotConstructor,
-+ DeadProxyBackgroundFinalized::Yes>::singleton();
-
- return NewProxyObject(cx, handler, NullHandleValue, nullptr, ProxyOptions());
- }
-diff --git js/src/proxy/DeadObjectProxy.h js/src/proxy/DeadObjectProxy.h
-index 42f21288d0e3..f29c972cf10a 100644
---- js/src/proxy/DeadObjectProxy.h
-+++ js/src/proxy/DeadObjectProxy.h
-@@ -21,7 +21,14 @@ enum DeadProxyIsCallableIsConstructorOption
- DeadProxyIsCallableIsConstructor
- };
-
--template <DeadProxyIsCallableIsConstructorOption CC>
-+enum class DeadProxyBackgroundFinalized
-+{
-+ Yes,
-+ No
-+};
-+
-+template <DeadProxyIsCallableIsConstructorOption CC,
-+ DeadProxyBackgroundFinalized BackgroundFinalized>
- class DeadObjectProxy : public BaseProxyHandler
- {
- public:
-@@ -70,6 +77,10 @@ class DeadObjectProxy : public BaseProxyHandler
- return CC == DeadProxyIsCallableIsConstructor || CC == DeadProxyNotCallableIsConstructor;
- }
-
-+ virtual bool finalizeInBackground(const JS::Value& priv) const override {
-+ return BackgroundFinalized == DeadProxyBackgroundFinalized::Yes;
-+ }
-+
- static const DeadObjectProxy* singleton() {
- static DeadObjectProxy singleton;
- return &singleton;
diff --git a/www/firefox/files/patch-bug1404324 b/www/firefox/files/patch-bug1404324
deleted file mode 100644
index afcbc3efb2ec..000000000000
--- a/www/firefox/files/patch-bug1404324
+++ /dev/null
@@ -1,299 +0,0 @@
-commit 5647dde295f4
-Author: Emilio Cobos Álvarez <emilio@crisal.io>
-Date: Wed Oct 4 11:36:20 2017 +0200
-
- Bug 1404324 - Use the placeholder state to remove out-of-flows that aren't real descendants of the destruction root. r=bz, a=ritu
-
- Using the style of the frame can mess things up when we reparent them due to
- ::first-line before removing them.
-
- MozReview-Commit-ID: 3Dt0wF2XRAH
-
- --HG--
- extra : source : 5a034cdb513208dd19adf0babf30ee734968a78f
- extra : histedit_source : 4cd958939c5a76e013695e931d721454268a0dc7%2C96bdeda302c567493c7db5105f306595d25332e1
----
- layout/base/nsCSSFrameConstructor.cpp | 8 +++---
- layout/base/nsLayoutUtils.cpp | 46 +++------------------------------
- layout/generic/nsPlaceholderFrame.cpp | 27 ++++++++++++++++---
- layout/generic/nsPlaceholderFrame.h | 21 ++++++++-------
- layout/style/crashtests/1404324-1.html | 12 +++++++++
- layout/style/crashtests/1404324-2.html | 10 +++++++
- layout/style/crashtests/1404324-3.html | 14 ++++++++++
- layout/style/crashtests/crashtests.list | 3 +++
- 8 files changed, 83 insertions(+), 58 deletions(-)
-
-diff --git layout/base/nsCSSFrameConstructor.cpp layout/base/nsCSSFrameConstructor.cpp
-index c840416fd6a7..99b1211b399b 100644
---- layout/base/nsCSSFrameConstructor.cpp
-+++ layout/base/nsCSSFrameConstructor.cpp
-@@ -1260,8 +1260,10 @@ nsFrameConstructorState::GetOutOfFlowFrameItems(nsIFrame* aNewFrame,
- if (disp->mTopLayer != NS_STYLE_TOP_LAYER_NONE) {
- *aPlaceholderType = PLACEHOLDER_FOR_TOPLAYER;
- if (disp->mPosition == NS_STYLE_POSITION_FIXED) {
-+ *aPlaceholderType |= PLACEHOLDER_FOR_FIXEDPOS;
- return &mTopLayerFixedItems;
- }
-+ *aPlaceholderType |= PLACEHOLDER_FOR_ABSPOS;
- return &mTopLayerAbsoluteItems;
- }
- if (disp->mPosition == NS_STYLE_POSITION_ABSOLUTE) {
-@@ -1303,11 +1305,11 @@ nsFrameConstructorState::ConstructBackdropFrameFor(nsIContent* aContent,
- nsAbsoluteItems* frameItems = GetOutOfFlowFrameItems(backdropFrame,
- true, true, false,
- &placeholderType);
-- MOZ_ASSERT(placeholderType == PLACEHOLDER_FOR_TOPLAYER);
-+ MOZ_ASSERT(placeholderType & PLACEHOLDER_FOR_TOPLAYER);
-
- nsIFrame* placeholder = nsCSSFrameConstructor::
- CreatePlaceholderFrameFor(mPresShell, aContent, backdropFrame,
-- frame, nullptr, PLACEHOLDER_FOR_TOPLAYER);
-+ frame, nullptr, placeholderType);
- nsFrameList temp(placeholder, placeholder);
- frame->SetInitialChildList(nsIFrame::kBackdropList, temp);
-
-@@ -1361,7 +1363,7 @@ nsFrameConstructorState::AddChild(nsIFrame* aNewFrame,
- // Add the placeholder frame to the flow
- aFrameItems.AddChild(placeholderFrame);
-
-- if (placeholderType == PLACEHOLDER_FOR_TOPLAYER) {
-+ if (placeholderType & PLACEHOLDER_FOR_TOPLAYER) {
- ConstructBackdropFrameFor(aContent, aNewFrame);
- }
- }
-diff --git layout/base/nsLayoutUtils.cpp layout/base/nsLayoutUtils.cpp
-index cb010c0a1a80..94ead9830c25 100644
---- layout/base/nsLayoutUtils.cpp
-+++ layout/base/nsLayoutUtils.cpp
-@@ -1525,6 +1525,8 @@ nsLayoutUtils::GetChildListNameFor(nsIFrame* aChildFrame)
- {
- nsIFrame::ChildListID id = nsIFrame::kPrincipalList;
-
-+ MOZ_DIAGNOSTIC_ASSERT(!(aChildFrame->GetStateBits() & NS_FRAME_OUT_OF_FLOW));
-+
- if (aChildFrame->GetStateBits() & NS_FRAME_IS_OVERFLOW_CONTAINER) {
- nsIFrame* pif = aChildFrame->GetPrevInFlow();
- if (pif->GetParent() == aChildFrame->GetParent()) {
-@@ -1533,35 +1535,6 @@ nsLayoutUtils::GetChildListNameFor(nsIFrame* aChildFrame)
- else {
- id = nsIFrame::kOverflowContainersList;
- }
-- }
-- // See if the frame is moved out of the flow
-- else if (aChildFrame->GetStateBits() & NS_FRAME_OUT_OF_FLOW) {
-- // Look at the style information to tell
-- const nsStyleDisplay* disp = aChildFrame->StyleDisplay();
--
-- if (NS_STYLE_POSITION_ABSOLUTE == disp->mPosition) {
-- id = nsIFrame::kAbsoluteList;
-- } else if (NS_STYLE_POSITION_FIXED == disp->mPosition) {
-- if (nsLayoutUtils::IsReallyFixedPos(aChildFrame)) {
-- id = nsIFrame::kFixedList;
-- } else {
-- id = nsIFrame::kAbsoluteList;
-- }
--#ifdef MOZ_XUL
-- } else if (StyleDisplay::MozPopup == disp->mDisplay) {
-- // Out-of-flows that are DISPLAY_POPUP must be kids of the root popup set
--#ifdef DEBUG
-- nsIFrame* parent = aChildFrame->GetParent();
-- NS_ASSERTION(parent && parent->IsPopupSetFrame(), "Unexpected parent");
--#endif // DEBUG
--
-- id = nsIFrame::kPopupList;
--#endif // MOZ_XUL
-- } else {
-- NS_ASSERTION(aChildFrame->IsFloating(), "not a floated frame");
-- id = nsIFrame::kFloatList;
-- }
--
- } else {
- LayoutFrameType childType = aChildFrame->Type();
- if (LayoutFrameType::MenuPopup == childType) {
-@@ -1596,19 +1569,8 @@ nsLayoutUtils::GetChildListNameFor(nsIFrame* aChildFrame)
- nsContainerFrame* parent = aChildFrame->GetParent();
- bool found = parent->GetChildList(id).ContainsFrame(aChildFrame);
- if (!found) {
-- if (!(aChildFrame->GetStateBits() & NS_FRAME_OUT_OF_FLOW)) {
-- found = parent->GetChildList(nsIFrame::kOverflowList)
-- .ContainsFrame(aChildFrame);
-- }
-- else if (aChildFrame->IsFloating()) {
-- found = parent->GetChildList(nsIFrame::kOverflowOutOfFlowList)
-- .ContainsFrame(aChildFrame);
-- if (!found) {
-- found = parent->GetChildList(nsIFrame::kPushedFloatsList)
-- .ContainsFrame(aChildFrame);
-- }
-- }
-- // else it's positioned and should have been on the 'id' child list.
-+ found = parent->GetChildList(nsIFrame::kOverflowList)
-+ .ContainsFrame(aChildFrame);
- NS_POSTCONDITION(found, "not in child list");
- }
- #endif
-diff --git layout/generic/nsPlaceholderFrame.cpp layout/generic/nsPlaceholderFrame.cpp
-index 7da2582ae526..4b2e1bf84b36 100644
---- layout/generic/nsPlaceholderFrame.cpp
-+++ layout/generic/nsPlaceholderFrame.cpp
-@@ -25,9 +25,9 @@ using namespace mozilla::gfx;
-
- nsIFrame*
- NS_NewPlaceholderFrame(nsIPresShell* aPresShell, nsStyleContext* aContext,
-- nsFrameState aTypeBit)
-+ nsFrameState aTypeBits)
- {
-- return new (aPresShell) nsPlaceholderFrame(aContext, aTypeBit);
-+ return new (aPresShell) nsPlaceholderFrame(aContext, aTypeBits);
- }
-
- NS_IMPL_FRAMEARENA_HELPERS(nsPlaceholderFrame)
-@@ -155,6 +155,26 @@ nsPlaceholderFrame::Reflow(nsPresContext* aPresContext,
- NS_FRAME_SET_TRUNCATION(aStatus, aReflowInput, aDesiredSize);
- }
-
-+static nsIFrame::ChildListID
-+ChildListIDForOutOfFlow(nsFrameState aPlaceholderState, nsIFrame* aChild)
-+{
-+ if (aPlaceholderState & PLACEHOLDER_FOR_FLOAT) {
-+ return nsIFrame::kFloatList;
-+ }
-+ if (aPlaceholderState & PLACEHOLDER_FOR_POPUP) {
-+ return nsIFrame::kPopupList;
-+ }
-+ if (aPlaceholderState & PLACEHOLDER_FOR_FIXEDPOS) {
-+ return nsLayoutUtils::IsReallyFixedPos(aChild)
-+ ? nsIFrame::kFixedList : nsIFrame::kAbsoluteList;
-+ }
-+ if (aPlaceholderState & PLACEHOLDER_FOR_ABSPOS) {
-+ return nsIFrame::kAbsoluteList;
-+ }
-+ MOZ_DIAGNOSTIC_ASSERT(false, "unknown list");
-+ return nsIFrame::kFloatList;
-+}
-+
- void
- nsPlaceholderFrame::DestroyFrom(nsIFrame* aDestructRoot)
- {
-@@ -162,12 +182,13 @@ nsPlaceholderFrame::DestroyFrom(nsIFrame* aDestructRoot)
- if (oof) {
- mOutOfFlowFrame = nullptr;
- oof->DeleteProperty(nsIFrame::PlaceholderFrameProperty());
-+
- // If aDestructRoot is not an ancestor of the out-of-flow frame,
- // then call RemoveFrame on it here.
- // Also destroy it here if it's a popup frame. (Bug 96291)
- if ((GetStateBits() & PLACEHOLDER_FOR_POPUP) ||
- !nsLayoutUtils::IsProperAncestorFrame(aDestructRoot, oof)) {
-- ChildListID listId = nsLayoutUtils::GetChildListNameFor(oof);
-+ ChildListID listId = ChildListIDForOutOfFlow(GetStateBits(), oof);
- nsFrameManager* fm = PresContext()->GetPresShell()->FrameManager();
- fm->RemoveFrame(listId, oof);
- }
-diff --git layout/generic/nsPlaceholderFrame.h layout/generic/nsPlaceholderFrame.h
-index e270c76cdd31..2af9b4ccbc93 100644
---- layout/generic/nsPlaceholderFrame.h
-+++ layout/generic/nsPlaceholderFrame.h
-@@ -40,7 +40,7 @@
-
- nsIFrame* NS_NewPlaceholderFrame(nsIPresShell* aPresShell,
- nsStyleContext* aContext,
-- nsFrameState aTypeBit);
-+ nsFrameState aTypeBits);
-
- #define PLACEHOLDER_TYPE_MASK (PLACEHOLDER_FOR_FLOAT | \
- PLACEHOLDER_FOR_ABSPOS | \
-@@ -65,18 +65,19 @@ public:
- */
- friend nsIFrame* NS_NewPlaceholderFrame(nsIPresShell* aPresShell,
- nsStyleContext* aContext,
-- nsFrameState aTypeBit);
-- nsPlaceholderFrame(nsStyleContext* aContext, nsFrameState aTypeBit)
-+ nsFrameState aTypeBits);
-+ nsPlaceholderFrame(nsStyleContext* aContext, nsFrameState aTypeBits)
- : nsFrame(aContext, kClassID)
- , mOutOfFlowFrame(nullptr)
- {
-- NS_PRECONDITION(aTypeBit == PLACEHOLDER_FOR_FLOAT ||
-- aTypeBit == PLACEHOLDER_FOR_ABSPOS ||
-- aTypeBit == PLACEHOLDER_FOR_FIXEDPOS ||
-- aTypeBit == PLACEHOLDER_FOR_POPUP ||
-- aTypeBit == PLACEHOLDER_FOR_TOPLAYER,
-- "Unexpected type bit");
-- AddStateBits(aTypeBit);
-+ MOZ_ASSERT(aTypeBits == PLACEHOLDER_FOR_FLOAT ||
-+ aTypeBits == PLACEHOLDER_FOR_ABSPOS ||
-+ aTypeBits == PLACEHOLDER_FOR_FIXEDPOS ||
-+ aTypeBits == PLACEHOLDER_FOR_POPUP ||
-+ aTypeBits == (PLACEHOLDER_FOR_TOPLAYER | PLACEHOLDER_FOR_ABSPOS) ||
-+ aTypeBits == (PLACEHOLDER_FOR_TOPLAYER | PLACEHOLDER_FOR_FIXEDPOS),
-+ "Unexpected type bit");
-+ AddStateBits(aTypeBits);
- }
-
- // Get/Set the associated out of flow frame
-diff --git layout/style/crashtests/1404324-1.html layout/style/crashtests/1404324-1.html
-new file mode 100644
-index 000000000000..574a5437cb1b
---- /dev/null
-+++ layout/style/crashtests/1404324-1.html
-@@ -0,0 +1,12 @@
-+<style></style>
-+<script>
-+document.documentElement.className = 'c1'
-+o1 = document.createElement('form')
-+o2 = document.createElement('e')
-+o1.className = 'c2'
-+document.documentElement.appendChild(o1)
-+document.documentElement.appendChild(o2)
-+document.styleSheets[0].insertRule('.c1:first-line, .c2 { position:fixed', 0);
-+document.documentElement.getBoundingClientRect()
-+document.styleSheets[0].cssRules[0].style.position = 'relative'
-+</script>
-diff --git layout/style/crashtests/1404324-2.html layout/style/crashtests/1404324-2.html
-new file mode 100644
-index 000000000000..797347d5c058
---- /dev/null
-+++ layout/style/crashtests/1404324-2.html
-@@ -0,0 +1,10 @@
-+<style>
-+ del, *::first-line {
-+ position: absolute;
-+ }
-+</style>
-+<del></del>
-+<script>
-+ document.documentElement.offsetTop;
-+ document.styleSheets[0].cssRules[0].style.position = 'sticky'
-+</script>
-diff --git layout/style/crashtests/1404324-3.html layout/style/crashtests/1404324-3.html
-new file mode 100644
-index 000000000000..3b06f12a2bf6
---- /dev/null
-+++ layout/style/crashtests/1404324-3.html
-@@ -0,0 +1,14 @@
-+<style>
-+del {
-+ position: absolute;
-+}
-+
-+body::first-line {
-+ color: red;
-+}
-+</style>
-+<del></del>
-+<script>
-+ document.documentElement.offsetTop;
-+ document.styleSheets[0].cssRules[0].style.position = 'sticky'
-+</script>
-diff --git layout/style/crashtests/crashtests.list layout/style/crashtests/crashtests.list
-index be9a46c52bfa..5eaba6935ee2 100644
---- layout/style/crashtests/crashtests.list
-+++ layout/style/crashtests/crashtests.list
-@@ -238,3 +238,6 @@ load 1403615.html
- load 1387481-1.html
- load 1387499.html
- load 1391577.html
-+asserts-if(stylo,1) load 1404324-1.html # bug 1405605
-+load 1404324-2.html
-+load 1404324-3.html
diff --git a/www/firefox/files/patch-bug1404636 b/www/firefox/files/patch-bug1404636
deleted file mode 100644
index 0fcf35bcb131..000000000000
--- a/www/firefox/files/patch-bug1404636
+++ /dev/null
@@ -1,111 +0,0 @@
-commit 3eff0850dd67
-Author: Jan de Mooij <jdemooij@mozilla.com>
-Date: Thu Oct 26 16:15:35 2017 +0200
-
- Bug 1404636 - Special-case typed arrays in PropertyReadNeedsTypeBarrier. r=bhackett, a=lizzard
-
- --HG--
- extra : source : 74d76655c9192b20dc69ddfa40c38e65fa9a47e3
----
- js/src/jit/IonBuilder.cpp | 26 --------------------------
- js/src/jit/MIR.cpp | 8 ++++++++
- js/src/jit/MIR.h | 23 +++++++++++++++++++++++
- 3 files changed, 31 insertions(+), 26 deletions(-)
-
-diff --git js/src/jit/IonBuilder.cpp js/src/jit/IonBuilder.cpp
-index 0f78e9d5d3b7..f0ef380da2bc 100644
---- js/src/jit/IonBuilder.cpp
-+++ js/src/jit/IonBuilder.cpp
-@@ -7825,9 +7825,6 @@ IonBuilder::getElemTryTypedObject(bool* emitted, MDefinition* obj, MDefinition*
- MOZ_CRASH("Bad kind");
- }
-
--static MIRType
--MIRTypeForTypedArrayRead(Scalar::Type arrayType, bool observedDouble);
--
- bool
- IonBuilder::checkTypedObjectIndexInBounds(uint32_t elemSize,
- MDefinition* obj,
-@@ -8793,29 +8790,6 @@ IonBuilder::convertShiftToMaskForStaticTypedArray(MDefinition* id,
- return ptr;
- }
-
--static MIRType
--MIRTypeForTypedArrayRead(Scalar::Type arrayType, bool observedDouble)
--{
-- switch (arrayType) {
-- case Scalar::Int8:
-- case Scalar::Uint8:
-- case Scalar::Uint8Clamped:
-- case Scalar::Int16:
-- case Scalar::Uint16:
-- case Scalar::Int32:
-- return MIRType::Int32;
-- case Scalar::Uint32:
-- return observedDouble ? MIRType::Double : MIRType::Int32;
-- case Scalar::Float32:
-- return MIRType::Float32;
-- case Scalar::Float64:
-- return MIRType::Double;
-- default:
-- break;
-- }
-- MOZ_CRASH("Unknown typed array type");
--}
--
- AbortReasonOr<Ok>
- IonBuilder::jsop_getelem_typed(MDefinition* obj, MDefinition* index,
- Scalar::Type arrayType)
-diff --git js/src/jit/MIR.cpp js/src/jit/MIR.cpp
-index bac5948bfc21..ef286b7d546c 100644
---- js/src/jit/MIR.cpp
-+++ js/src/jit/MIR.cpp
-@@ -6235,6 +6235,14 @@ PropertyReadNeedsTypeBarrier(CompilerConstraintList* constraints,
- return BarrierKind::TypeSet;
- }
-
-+ if (!name && IsTypedArrayClass(key->clasp())) {
-+ Scalar::Type arrayType = Scalar::Type(key->clasp() - &TypedArrayObject::classes[0]);
-+ MIRType type = MIRTypeForTypedArrayRead(arrayType, true);
-+ if (observed->mightBeMIRType(type))
-+ return BarrierKind::NoBarrier;
-+ return BarrierKind::TypeSet;
-+ }
-+
- jsid id = name ? NameToId(name) : JSID_VOID;
- HeapTypeSetKey property = key->property(id);
- if (property.maybeTypes()) {
-diff --git js/src/jit/MIR.h js/src/jit/MIR.h
-index d6d895b2caf2..16824b3f67ad 100644
---- js/src/jit/MIR.h
-+++ js/src/jit/MIR.h
-@@ -15107,6 +15107,29 @@ ArrayPrototypeHasIndexedProperty(IonBuilder* builder, JSScript* script);
- AbortReasonOr<bool>
- TypeCanHaveExtraIndexedProperties(IonBuilder* builder, TemporaryTypeSet* types);
-
-+inline MIRType
-+MIRTypeForTypedArrayRead(Scalar::Type arrayType, bool observedDouble)
-+{
-+ switch (arrayType) {
-+ case Scalar::Int8:
-+ case Scalar::Uint8:
-+ case Scalar::Uint8Clamped:
-+ case Scalar::Int16:
-+ case Scalar::Uint16:
-+ case Scalar::Int32:
-+ return MIRType::Int32;
-+ case Scalar::Uint32:
-+ return observedDouble ? MIRType::Double : MIRType::Int32;
-+ case Scalar::Float32:
-+ return MIRType::Float32;
-+ case Scalar::Float64:
-+ return MIRType::Double;
-+ default:
-+ break;
-+ }
-+ MOZ_CRASH("Unknown typed array type");
-+}
-+
- } // namespace jit
- } // namespace js
-
diff --git a/www/firefox/files/patch-bug1404910 b/www/firefox/files/patch-bug1404910
deleted file mode 100644
index 1157ce538381..000000000000
--- a/www/firefox/files/patch-bug1404910
+++ /dev/null
@@ -1,170 +0,0 @@
-commit 2c8bf0ecbc5d
-Author: Andrea Marchesini <amarchesini@mozilla.com>
-Date: Wed Oct 4 14:18:19 2017 +0200
-
- Bug 1404910 - WebSocket should consider the corrent top-level window principal. r=smaug, a=ritu
-
- --HG--
- extra : source : c543c0a50db700883b57c052710c97b5ef731e1f
----
- dom/base/WebSocket.cpp | 15 ++++---
- dom/base/test/iframe_webSocket_sandbox.html | 65 +++++++++++++++++++++++++++++
- dom/base/test/mochitest.ini | 3 ++
- dom/base/test/test_webSocket_sandbox.html | 34 +++++++++++++++
- 4 files changed, 109 insertions(+), 8 deletions(-)
-
-diff --git dom/base/WebSocket.cpp dom/base/WebSocket.cpp
-index dc2c1c70107b..982c67cd2abd 100644
---- dom/base/WebSocket.cpp
-+++ dom/base/WebSocket.cpp
-@@ -1666,18 +1666,17 @@ WebSocketImpl::Init(JSContext* aCx,
- nsCOMPtr<nsPIDOMWindowInner> innerWindow;
-
- while (true) {
-- if (principal) {
-- bool isNullPrincipal = true;
-- isNullPrincipal = principal->GetIsNullPrincipal();
-- if (isNullPrincipal || nsContentUtils::IsSystemPrincipal(principal)) {
-- break;
-- }
-+ if (principal && !principal->GetIsNullPrincipal()) {
-+ break;
- }
-
- if (!innerWindow) {
- innerWindow = do_QueryInterface(globalObject);
-- if (NS_WARN_IF(!innerWindow)) {
-- return NS_ERROR_DOM_SECURITY_ERR;
-+ if (!innerWindow) {
-+ // If we are in a XPConnect sandbox or in a JS component,
-+ // innerWindow will be null. There is nothing on top of this to be
-+ // considered.
-+ break;
- }
- }
-
-diff --git dom/base/test/iframe_webSocket_sandbox.html dom/base/test/iframe_webSocket_sandbox.html
-new file mode 100644
-index 000000000000..d889a79b05da
---- /dev/null
-+++ dom/base/test/iframe_webSocket_sandbox.html
-@@ -0,0 +1,65 @@
-+<html><body>
-+<iframe id="frame" sandbox="allow-scripts allow-popups"></iframe>
-+<script type="application/javascript;version=1.8">
-+onmessage = function(e) {
-+ parent.postMessage(e.data, '*');
-+}
-+
-+var ifr = document.getElementById('frame');
-+
-+if (location.search == '?nested') {
-+ var url = new URL(location);
-+ url.search = "";
-+ ifr.src = url.href;
-+} else if (location.search == '?popup') {
-+ var url = new URL(location);
-+ url.search = "?opener";
-+
-+ ifr.srcdoc = "<html><script>" +
-+ "window.open('" + url.href + "', 'foobar');" +
-+ "onmessage = function(e) { " +
-+ " parent.postMessage(e.data, '*'); " +
-+ "}" +
-+ "</scr" + "ipt></html>";
-+} else if (location.search == '?opener') {
-+ try{
-+ var socket = new WebSocket('ws://mochi.test:8888/tests/dom/base/test/file_websocket_basic');
-+ socket.onerror = function(e) {
-+ opener.postMessage('WS onerror', '*');
-+ close();
-+ };
-+ socket.onopen = function(event) {
-+ opener.postMessage('WS onopen', '*');
-+ close();
-+ };
-+ } catch(e) {
-+ if (e.name == 'SecurityError') {
-+ opener.postMessage('WS Throws!', '*');
-+ } else {
-+ opener.postMessage('WS Throws something else!', '*');
-+ }
-+ close();
-+ }
-+} else {
-+ ifr.srcdoc = `
-+ <html><script>
-+ try{
-+ var socket = new WebSocket('ws://mochi.test:8888/tests/dom/base/test/file_websocket_basic');
-+ socket.onerror = function(e) {
-+ parent.postMessage('WS onerror', '*');
-+ };
-+ socket.onopen = function(event) {
-+ parent.postMessage('WS onopen', '*');
-+ };
-+ } catch(e) {
-+ if (e.name == 'SecurityError') {
-+ parent.postMessage('WS Throws!', '*');
-+ } else {
-+ parent.postMessage('WS Throws something else!', '*');
-+ }
-+ }
-+ </scr`+`ipt>
-+ </html>`;
-+}
-+</script>
-+</body></html>
-diff --git dom/base/test/mochitest.ini dom/base/test/mochitest.ini
-index 670dd5ae0a06..5d59fe1ea7b8 100644
---- dom/base/test/mochitest.ini
-+++ dom/base/test/mochitest.ini
-@@ -804,6 +804,9 @@ skip-if = toolkit == 'android'
- skip-if = toolkit == 'android'
- [test_websocket_permessage_deflate.html]
- skip-if = toolkit == 'android'
-+[test_webSocket_sandbox.html]
-+skip-if = toolkit == 'android'
-+support-files = iframe_webSocket_sandbox.html
- [test_websocket1.html]
- skip-if = toolkit == 'android'
- [test_websocket2.html]
-diff --git dom/base/test/test_webSocket_sandbox.html dom/base/test/test_webSocket_sandbox.html
-new file mode 100644
-index 000000000000..b343fa784f39
---- /dev/null
-+++ dom/base/test/test_webSocket_sandbox.html
-@@ -0,0 +1,34 @@
-+<!DOCTYPE HTML>
-+<html>
-+<head>
-+ <title>Bug 1252751</title>
-+ <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
-+ <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
-+</head>
-+<body>
-+<div id="container"></div>
-+<iframe id="frame"></iframe>
-+<script type="application/javascript;version=1.8">
-+var urls = [ "https://example.com/tests/dom/base/test/iframe_webSocket_sandbox.html",
-+ "https://example.com/tests/dom/base/test/iframe_webSocket_sandbox.html?nested",
-+ "https://example.com/tests/dom/base/test/iframe_webSocket_sandbox.html?popup" ];
-+
-+onmessage = function(e) {
-+ is(e.data, "WS Throws!", "ws://URI cannot be used by a https iframe");
-+ runTest();
-+}
-+
-+function runTest() {
-+ if (!urls.length) {
-+ SimpleTest.finish();
-+ return;
-+ }
-+
-+ document.getElementById("frame").src = urls.shift();
-+}
-+
-+SimpleTest.waitForExplicitFinish();
-+runTest();
-+</script>
-+</body>
-+</html>
diff --git a/www/firefox/files/patch-bug1406154 b/www/firefox/files/patch-bug1406154
deleted file mode 100644
index d10858205a0b..000000000000
--- a/www/firefox/files/patch-bug1406154
+++ /dev/null
@@ -1,53 +0,0 @@
-commit 3708901c15ba
-Author: Byron Campen [:bwc] <docfaraday@gmail.com>
-Date: Thu Oct 12 12:12:40 2017 -0500
-
- Bug 1406154 - Ensure that we avoid truncating the interface description strings in a couple of corner cases. r=drno, a=sledru
-
- MozReview-Commit-ID: KMTpbkvA4N
-
- --HG--
- extra : source : 5c8d4905c2bdbb3cfa0db5e07a3cd6ba4eb23fdd
----
- media/mtransport/nrinterfaceprioritizer.cpp | 2 +-
- media/mtransport/third_party/nICEr/src/net/transport_addr.c | 6 +++++-
- 2 files changed, 6 insertions(+), 2 deletions(-)
-
-diff --git media/mtransport/nrinterfaceprioritizer.cpp media/mtransport/nrinterfaceprioritizer.cpp
-index 37756991239c..34b941c53a45 100644
---- media/mtransport/nrinterfaceprioritizer.cpp
-+++ media/mtransport/nrinterfaceprioritizer.cpp
-@@ -28,7 +28,7 @@ public:
- bool Init(const nr_local_addr& local_addr) {
- ifname_ = local_addr.addr.ifname;
-
-- char buf[MAXIFNAME + 41];
-+ char buf[MAXIFNAME + 47];
- int r = nr_transport_addr_fmt_ifname_addr_string(&local_addr.addr, buf, sizeof(buf));
- if (r) {
- MOZ_MTLOG(ML_ERROR, "Error formatting interface key.");
-diff --git media/mtransport/third_party/nICEr/src/net/transport_addr.c media/mtransport/third_party/nICEr/src/net/transport_addr.c
-index 99564a08e8b9..ae849f43387e 100644
---- media/mtransport/third_party/nICEr/src/net/transport_addr.c
-+++ media/mtransport/third_party/nICEr/src/net/transport_addr.c
-@@ -98,7 +98,8 @@ int nr_transport_addr_fmt_addr_string(nr_transport_addr *addr)
- int nr_transport_addr_fmt_ifname_addr_string(const nr_transport_addr *addr, char *buf, int len)
- {
- int _status;
-- char buffer[40];
-+ /* leave room for a fully-expanded IPV4-mapped IPV6 address */
-+ char buffer[46];
-
- switch(addr->ip_version){
- case NR_IPV4:
-@@ -114,7 +115,10 @@ int nr_transport_addr_fmt_ifname_addr_string(const nr_transport_addr *addr, char
- default:
- ABORT(R_INTERNAL);
- }
-+ buffer[sizeof(buffer) - 1] = '\0';
-+
- snprintf(buf,len,"%s:%s",addr->ifname,buffer);
-+ buf[len - 1] = '\0';
-
- _status=0;
- abort:
diff --git a/www/firefox/files/patch-bug1406398 b/www/firefox/files/patch-bug1406398
deleted file mode 100644
index 356c2bde3746..000000000000
--- a/www/firefox/files/patch-bug1406398
+++ /dev/null
@@ -1,36 +0,0 @@
-commit c79dd79bdb5c
-Author: André Bargull <andre.bargull@gmail.com>
-Date: Thu Oct 12 09:20:07 2017 -0700
-
- Bug 1406398 - Avoid rooting the object twice in EnumerableOwnProperties. r=jandem, a=lizzard
-
- --HG--
- extra : source : c2cecb6d6f9bb85f258a66cf8e94c1860adde7e5
----
- js/src/builtin/Object.cpp | 6 ++----
- 1 file changed, 2 insertions(+), 4 deletions(-)
-
-diff --git js/src/builtin/Object.cpp js/src/builtin/Object.cpp
-index dff377a1cd97..ff4dd029cb52 100644
---- js/src/builtin/Object.cpp
-+++ js/src/builtin/Object.cpp
-@@ -1246,9 +1246,6 @@ EnumerableOwnProperties(JSContext* cx, const JS::CallArgs& args, EnumerableOwnPr
- RootedId id(cx);
- RootedValue key(cx);
- RootedValue value(cx);
-- RootedNativeObject nobj(cx);
-- if (obj->is<NativeObject>())
-- nobj = &obj->as<NativeObject>();
- RootedShape shape(cx);
- Rooted<PropertyDescriptor> desc(cx);
- // Step 4.
-@@ -1265,7 +1262,8 @@ EnumerableOwnProperties(JSContext* cx, const JS::CallArgs& args, EnumerableOwnPr
- }
-
- // Step 4.a.i.
-- if (nobj) {
-+ if (obj->is<NativeObject>()) {
-+ HandleNativeObject nobj = obj.as<NativeObject>();
- if (JSID_IS_INT(id) && nobj->containsDenseElement(JSID_TO_INT(id))) {
- value = nobj->getDenseOrTypedArrayElement(JSID_TO_INT(id));
- } else {
diff --git a/www/firefox/files/patch-bug1406750 b/www/firefox/files/patch-bug1406750
deleted file mode 100644
index 0235d6d7c907..000000000000
--- a/www/firefox/files/patch-bug1406750
+++ /dev/null
@@ -1,47 +0,0 @@
-commit f2e38d27a7e3
-Author: Emilio Cobos Álvarez <emilio@crisal.io>
-Date: Tue Oct 24 17:44:12 2017 -0400
-
- Bug 1406750 - Use GetStyleContextNoFlush in UpdateCurrentStyleSources, and avoid flushing mPresShell twice. r=bz, a=abillings
-
- MozReview-Commit-ID: Nfu9FZcIzQ
-
- --HG--
- extra : source : c73db1c3b6e78a5fad216ca7cc7e4ce312c30a98
- extra : amend_source : 9b31fa281368a9dc39a4a949cb85ae2f354a4308
----
- layout/style/nsComputedDOMStyle.cpp | 14 ++++++++++----
- 1 file changed, 10 insertions(+), 4 deletions(-)
-
-diff --git layout/style/nsComputedDOMStyle.cpp layout/style/nsComputedDOMStyle.cpp
-index 062e00ffebc5..1aa07e691d4a 100644
---- layout/style/nsComputedDOMStyle.cpp
-+++ layout/style/nsComputedDOMStyle.cpp
-@@ -832,6 +832,11 @@ nsComputedDOMStyle::UpdateCurrentStyleSources(bool aNeedsLayoutFlush)
- return;
- }
-
-+ nsCOMPtr<nsIPresShell> presShellForContent = GetPresShellForContent(mContent);
-+ if (presShellForContent && presShellForContent != mPresShell) {
-+ presShellForContent->FlushPendingNotifications(FlushType::Style);
-+ }
-+
- // We need to use GetUndisplayedRestyleGeneration instead of
- // GetRestyleGeneration, because the caching of mStyleContext is an
- // optimization that is useful only for displayed elements.
-@@ -922,10 +927,11 @@ nsComputedDOMStyle::UpdateCurrentStyleSources(bool aNeedsLayoutFlush)
- #endif
- // Need to resolve a style context
- RefPtr<nsStyleContext> resolvedStyleContext =
-- nsComputedDOMStyle::GetStyleContext(mContent->AsElement(),
-- mPseudo,
-- mPresShell,
-- mStyleType);
-+ nsComputedDOMStyle::GetStyleContextNoFlush(
-+ mContent->AsElement(),
-+ mPseudo,
-+ presShellForContent ? presShellForContent.get() : mPresShell,
-+ mStyleType);
- if (!resolvedStyleContext) {
- ClearStyleContext();
- return;
diff --git a/www/firefox/files/patch-bug1407032 b/www/firefox/files/patch-bug1407032
deleted file mode 100644
index 70f2017d77ab..000000000000
--- a/www/firefox/files/patch-bug1407032
+++ /dev/null
@@ -1,48 +0,0 @@
-commit 5666a545d8a1
-Author: David Anderson <danderson@mozilla.com>
-Date: Mon Oct 23 16:18:24 2017 -0400
-
- Bug 1407032 - Reorder when GPUProcessHosts are destroyed. r=rhunt, a=ritu
-
- --HG--
- extra : source : 2fb069813d832de4338028cf84c8dab483ba0fda
----
- gfx/ipc/GPUProcessHost.cpp | 19 ++++++-------------
- 1 file changed, 6 insertions(+), 13 deletions(-)
-
-diff --git gfx/ipc/GPUProcessHost.cpp gfx/ipc/GPUProcessHost.cpp
-index 544baea242cf..249decc52a95 100644
---- gfx/ipc/GPUProcessHost.cpp
-+++ gfx/ipc/GPUProcessHost.cpp
-@@ -190,25 +190,18 @@ GPUProcessHost::Shutdown()
- void
- GPUProcessHost::OnChannelClosed()
- {
-- if (!mShutdownRequested) {
-+ mChannelClosed = true;
-+
-+ if (!mShutdownRequested && mListener) {
- // This is an unclean shutdown. Notify our listener that we're going away.
-- mChannelClosed = true;
-- if (mListener) {
-- mListener->OnProcessUnexpectedShutdown(this);
-- }
-+ mListener->OnProcessUnexpectedShutdown(this);
-+ } else {
-+ DestroyProcess();
- }
-
- // Release the actor.
- GPUChild::Destroy(Move(mGPUChild));
- MOZ_ASSERT(!mGPUChild);
--
-- // If the owner of GPUProcessHost already requested shutdown, we can now
-- // schedule destruction. Otherwise we must wait for someone to call
-- // Shutdown. Note that GPUProcessManager calls Shutdown within
-- // OnProcessUnexpectedShutdown.
-- if (mShutdownRequested) {
-- DestroyProcess();
-- }
- }
-
- void
diff --git a/www/firefox/files/patch-bug1407375 b/www/firefox/files/patch-bug1407375
deleted file mode 100644
index 6768dc9bc072..000000000000
--- a/www/firefox/files/patch-bug1407375
+++ /dev/null
@@ -1,28 +0,0 @@
-commit b2d46387afc9
-Author: Boris Zbarsky <bzbarsky@mit.edu>
-Date: Wed Oct 11 22:19:06 2017 -0400
-
- Bug 1407375 - Make sure to call NodeInfoChanged whenever we change the nodeinfo on a node. r=peterv, a=ritu
-
- MozReview-Commit-ID: 71k1jv8thFA
-
- --HG--
- extra : source : 51ff2d13e50c1e8f7731e4c7243064bb96d2e4d0
----
- dom/base/nsNodeUtils.cpp | 3 +++
- 1 file changed, 3 insertions(+)
-
-diff --git dom/base/nsNodeUtils.cpp dom/base/nsNodeUtils.cpp
-index 64ab9e852966..dd958aa443ce 100644
---- dom/base/nsNodeUtils.cpp
-+++ dom/base/nsNodeUtils.cpp
-@@ -593,6 +593,9 @@ nsNodeUtils::CloneAndAdopt(nsINode *aNode, bool aClone, bool aDeep,
- aNode->OwnerDoc()->UnregisterActivityObserver(aNode->AsElement());
- }
- aNode->mNodeInfo.swap(newNodeInfo);
-+ if (elem) {
-+ elem->NodeInfoChanged(newDoc);
-+ }
- if (wasRegistered) {
- aNode->OwnerDoc()->RegisterActivityObserver(aNode->AsElement());
- }
diff --git a/www/firefox/files/patch-bug1407740 b/www/firefox/files/patch-bug1407740
deleted file mode 100644
index 11f575fa40e2..000000000000
--- a/www/firefox/files/patch-bug1407740
+++ /dev/null
@@ -1,26 +0,0 @@
-commit a8fee72c6fc1
-Author: Andrew McCreight <continuation@gmail.com>
-Date: Fri Oct 20 16:11:26 2017 -0400
-
- Bug 1407740 - Fix a crash by setting a flag to true. r=bz, a=lizzard
-
- --HG--
- extra : source : 23d3b458f69c56b0f3b2b8faa1453f79e32ce70c
----
- docshell/base/nsDocShell.cpp | 3 +++
- 1 file changed, 3 insertions(+)
-
-diff --git docshell/base/nsDocShell.cpp docshell/base/nsDocShell.cpp
-index 6748a2722e5a..f7dc1508a74d 100644
---- docshell/base/nsDocShell.cpp
-+++ docshell/base/nsDocShell.cpp
-@@ -881,6 +881,9 @@ nsDocShell::~nsDocShell()
- {
- MOZ_ASSERT(!mObserved);
-
-+ // Avoid notifying observers while we're in the dtor.
-+ mIsBeingDestroyed = true;
-+
- Destroy();
-
- nsCOMPtr<nsISHistoryInternal> shPrivate(do_QueryInterface(mSessionHistory));
diff --git a/www/firefox/files/patch-bug1407751 b/www/firefox/files/patch-bug1407751
deleted file mode 100644
index c2137f510e1d..000000000000
--- a/www/firefox/files/patch-bug1407751
+++ /dev/null
@@ -1,35 +0,0 @@
-commit 390b56f13f00
-Author: Andrea Marchesini <amarchesini@mozilla.com>
-Date: Fri Oct 13 07:11:40 2017 +0200
-
- Bug 1407751 - DefineOSFileConstants should return false if OSFileConstants service is not initialized. r=froydnj, a=ritu
-
- --HG--
- extra : source : 2f76e40db328035331dd6aa79d0e5fbf04db7c96
----
- dom/system/OSFileConstants.cpp | 5 ++---
- 1 file changed, 2 insertions(+), 3 deletions(-)
-
-diff --git dom/system/OSFileConstants.cpp dom/system/OSFileConstants.cpp
-index edafe9f1c560..3cd77f6c3c12 100644
---- dom/system/OSFileConstants.cpp
-+++ dom/system/OSFileConstants.cpp
-@@ -346,6 +346,7 @@ void CleanupOSFileConstants()
-
- gInitialized = false;
- delete gPaths;
-+ gPaths = nullptr;
- }
-
-
-@@ -874,9 +875,7 @@ bool SetStringProperty(JSContext *cx, JS::Handle<JSObject*> aObject, const char
- */
- bool DefineOSFileConstants(JSContext *cx, JS::Handle<JSObject*> global)
- {
-- MOZ_ASSERT(gInitialized);
--
-- if (gPaths == nullptr) {
-+ if (!gInitialized || gPaths == nullptr) {
- // If an initialization error was ignored, we may end up with
- // |gInitialized == true| but |gPaths == nullptr|. We cannot
- // |MOZ_ASSERT| this, as this would kill precompile_cache.js,
diff --git a/www/firefox/files/patch-bug1408005 b/www/firefox/files/patch-bug1408005
deleted file mode 100644
index fafa9861305d..000000000000
--- a/www/firefox/files/patch-bug1408005
+++ /dev/null
@@ -1,25 +0,0 @@
-commit 988e61cc6282
-Author: Andrew McCreight <continuation@gmail.com>
-Date: Mon Oct 23 10:18:42 2017 -0400
-
- Bug 1408005 - Clear gApplicationReputationService in the dtor. r=francois, a=abillings
-
- --HG--
- extra : source : 1613834d8d1145200886a039f733b1e066c63cbd
----
- toolkit/components/downloads/ApplicationReputation.cpp | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git toolkit/components/downloads/ApplicationReputation.cpp toolkit/components/downloads/ApplicationReputation.cpp
-index b19841d8235d..18bc3b71728d 100644
---- toolkit/components/downloads/ApplicationReputation.cpp
-+++ toolkit/components/downloads/ApplicationReputation.cpp
-@@ -1576,6 +1576,8 @@ ApplicationReputationService::ApplicationReputationService()
-
- ApplicationReputationService::~ApplicationReputationService() {
- LOG(("Application reputation service shutting down"));
-+ MOZ_ASSERT(gApplicationReputationService == this);
-+ gApplicationReputationService = nullptr;
- }
-
- NS_IMETHODIMP
diff --git a/www/firefox/files/patch-bug1408412 b/www/firefox/files/patch-bug1408412
deleted file mode 100644
index 52ced3d9ec0d..000000000000
--- a/www/firefox/files/patch-bug1408412
+++ /dev/null
@@ -1,37 +0,0 @@
-commit 81f184512a09
-Author: Jan de Mooij <jdemooij@mozilla.com>
-Date: Wed Oct 25 11:30:17 2017 +0200
-
- Bug 1408412 - Use ARGS_LENGTH_MAX as upper bound in MArgumentsLength::computeRange. r=nbp, a=lizzard
-
- --HG--
- extra : source : aaf54dce048a85806833529a5d53ecc46156ef47
----
- js/src/jit/RangeAnalysis.cpp | 7 ++++---
- 1 file changed, 4 insertions(+), 3 deletions(-)
-
-diff --git js/src/jit/RangeAnalysis.cpp js/src/jit/RangeAnalysis.cpp
-index a3daefa848a7..19715ccc250a 100644
---- js/src/jit/RangeAnalysis.cpp
-+++ js/src/jit/RangeAnalysis.cpp
-@@ -15,6 +15,7 @@
- #include "jit/MIRGenerator.h"
- #include "jit/MIRGraph.h"
- #include "js/Conversions.h"
-+#include "vm/ArgumentsObject.h"
- #include "vm/TypedArrayObject.h"
-
- #include "jsopcodeinlines.h"
-@@ -1845,9 +1846,9 @@ MArgumentsLength::computeRange(TempAllocator& alloc)
- {
- // This is is a conservative upper bound on what |TooManyActualArguments|
- // checks. If exceeded, Ion will not be entered in the first place.
-- MOZ_ASSERT(JitOptions.maxStackArgs <= UINT32_MAX,
-- "NewUInt32Range requires a uint32 value");
-- setRange(Range::NewUInt32Range(alloc, 0, JitOptions.maxStackArgs));
-+ static_assert(ARGS_LENGTH_MAX <= UINT32_MAX,
-+ "NewUInt32Range requires a uint32 value");
-+ setRange(Range::NewUInt32Range(alloc, 0, ARGS_LENGTH_MAX));
- }
-
- void
diff --git a/www/firefox/files/patch-bug1408782 b/www/firefox/files/patch-bug1408782
deleted file mode 100644
index 8f197b018806..000000000000
--- a/www/firefox/files/patch-bug1408782
+++ /dev/null
@@ -1,55 +0,0 @@
-commit 5b8d4bd1ffaa
-Author: Jonathan Kew <jkew@mozilla.com>
-Date: Wed Oct 18 10:24:03 2017 +0100
-
- Bug 1408782 - Force punycode display for IDNs with a <dotless-i, combining mark above> sequence. r=valentin a=ritu
----
- netwerk/dns/nsIDNService.cpp | 9 +++++++++
- netwerk/test/unit/test_idn_urls.js | 7 +++++++
- 2 files changed, 16 insertions(+)
-
-diff --git netwerk/dns/nsIDNService.cpp netwerk/dns/nsIDNService.cpp
-index e07910a7e70d..a89b4301ea07 100644
---- netwerk/dns/nsIDNService.cpp
-+++ netwerk/dns/nsIDNService.cpp
-@@ -867,6 +867,7 @@ bool nsIDNService::isLabelSafe(const nsAString &label)
-
- Script lastScript = Script::INVALID;
- uint32_t previousChar = 0;
-+ uint32_t baseChar = 0; // last non-diacritic seen (base char for marks)
- uint32_t savedNumberingSystem = 0;
- // Simplified/Traditional Chinese check temporarily disabled -- bug 857481
- #if 0
-@@ -948,6 +949,14 @@ bool nsIDNService::isLabelSafe(const nsAString &label)
- }
- }
- }
-+ // Check for diacritics on dotless-i, which would be indistinguishable
-+ // from normal accented letter i.
-+ if (baseChar == 0x0131 &&
-+ ((ch >= 0x0300 && ch <= 0x0314) || ch == 0x031a)) {
-+ return false;
-+ }
-+ } else {
-+ baseChar = ch;
- }
-
- // Simplified/Traditional Chinese check temporarily disabled -- bug 857481
-diff --git netwerk/test/unit/test_idn_urls.js netwerk/test/unit/test_idn_urls.js
-index f39a9650a13b..e0d73ca512ee 100644
---- netwerk/test/unit/test_idn_urls.js
-+++ netwerk/test/unit/test_idn_urls.js
-@@ -300,6 +300,13 @@ const testcases = [
- ["goo\u0650gle", "xn--google-yri", false, false, false],
- // ...but Arabic diacritics are allowed on Arabic text
- ["العَرَبِي", "xn--mgbc0a5a6cxbzabt", false, true, true],
-+
-+ // Accents above dotless-i are not allowed
-+ ["na\u0131\u0308ve", "xn--nave-mza04z", false, false, false],
-+ ["d\u0131\u0302ner", "xn--dner-lza40z", false, false, false],
-+ // but the corresponding accented-i (based on dotted i) is OK
-+ ["na\u00efve.com", "xn--nave-6pa.com", false, true, true],
-+ ["d\u00eener.com", "xn--dner-0pa.com", false, true, true],
- ];
-
- const profiles = ["ASCII", "high", "moderate"];
diff --git a/www/firefox/files/patch-bug1408990 b/www/firefox/files/patch-bug1408990
deleted file mode 100644
index 9c089b728499..000000000000
--- a/www/firefox/files/patch-bug1408990
+++ /dev/null
@@ -1,34 +0,0 @@
-commit 53a3958e0a76
-Author: Valentin Gosu <valentin.gosu@gmail.com>
-Date: Sat Oct 28 00:15:01 2017 +0200
-
- Bug 1408990 - Only add the entry to the performance object if the loading document's principal is the same as the triggering principal. r=bz, r=dragana, a=lizzard
-
- MozReview-Commit-ID: 7o8XKHioP1p
-
- --HG--
- extra : rebase_source : 33d4044b4901cee460cc69a0bae1fe0e84dab2aa
- extra : source : ff9e841ff8544053f184d2e425500d5dd13ee14d
----
- netwerk/protocol/http/HttpBaseChannel.cpp | 8 ++++++++
- 1 file changed, 8 insertions(+)
-
-diff --git netwerk/protocol/http/HttpBaseChannel.cpp netwerk/protocol/http/HttpBaseChannel.cpp
-index 8a5c4d8d9f45..16e59241e2fc 100644
---- netwerk/protocol/http/HttpBaseChannel.cpp
-+++ netwerk/protocol/http/HttpBaseChannel.cpp
-@@ -4088,6 +4088,14 @@ HttpBaseChannel::GetPerformance()
- return nullptr;
- }
-
-+ // We only add to the document's performance object if it has the same
-+ // principal as the one triggering the load. This is to prevent navigations
-+ // triggered _by_ the iframe from showing up in the parent document's
-+ // performance entries if they have different origins.
-+ if (!mLoadInfo->TriggeringPrincipal()->Equals(loadingDocument->NodePrincipal())) {
-+ return nullptr;
-+ }
-+
- nsCOMPtr<nsPIDOMWindowInner> innerWindow = loadingDocument->GetInnerWindow();
- if (!innerWindow) {
- return nullptr;
diff --git a/www/firefox/files/patch-bug1409680 b/www/firefox/files/patch-bug1409680
deleted file mode 100644
index 37c71ec234b2..000000000000
--- a/www/firefox/files/patch-bug1409680
+++ /dev/null
@@ -1,27 +0,0 @@
-Bug 1409680 - Extend --disable-debug-symbols to Rust code.
-
-This reduces disk I/O and memory usage during build that already lacks
-debugging symbols from C++ code, allowing to use more jobs on 32bit hosts.
-
---disable-debug-symbols build on FreeBSD 10.3 i386 (8 cores) host:
-Max RSS before: libxul - 612 Mb, libgkrust - 1908 Mb
-Max RSS after: libxul - 444 Mb, libgkrust - 1471 Mb
-Binary before: libxul - 203 Mb, libgkrust - 732 Mb
-Binary after: libxul - 123 Mb, libgkrust - 301 Mb
-
---- config/rules.mk.orig 2017-09-14 20:15:53 UTC
-+++ config/rules.mk
-@@ -906,11 +906,13 @@ ifdef MOZ_USING_SCCACHE
- sccache_wrap := RUSTC_WRAPPER='$(CCACHE)'
- endif
-
-+ifdef MOZ_DEBUG_SYMBOLS
- # XXX hack to work around dsymutil failing on cross-OSX builds (bug 1380381)
- ifeq ($(HOST_OS_ARCH)-$(OS_ARCH),Linux-Darwin)
- default_rustflags += -C debuginfo=1
- else
- default_rustflags += -C debuginfo=2
-+endif
- endif
-
- # We use the + prefix to pass down the jobserver fds to cargo, but we
diff --git a/www/firefox/files/patch-bug1411458 b/www/firefox/files/patch-bug1411458
deleted file mode 100644
index 8caf1f602279..000000000000
--- a/www/firefox/files/patch-bug1411458
+++ /dev/null
@@ -1,44 +0,0 @@
-commit da2637dd8a23
-Author: David Keeler <dkeeler@mozilla.com>
-Date: Wed Oct 25 09:54:13 2017 -0700
-
- Bug 1411458 - Confirm we actually have a PKCS#7 signedData content info. r=jcj, a=ritu
-
- MozReview-Commit-ID: GKfL1C0EPWt
-
- --HG--
- extra : source : 22a772cfa62ae6908751b1cdd98a9234f2ea6105
----
- security/manager/ssl/nsDataSignatureVerifier.cpp | 6 ++++++
- security/nss.symbols | 1 +
- 2 files changed, 7 insertions(+)
-
-diff --git security/manager/ssl/nsDataSignatureVerifier.cpp security/manager/ssl/nsDataSignatureVerifier.cpp
-index f78740365e1a..2527431dd9ae 100644
---- security/manager/ssl/nsDataSignatureVerifier.cpp
-+++ security/manager/ssl/nsDataSignatureVerifier.cpp
-@@ -170,6 +170,12 @@ VerifyCMSDetachedSignatureIncludingCertificate(
- return NS_ERROR_CMS_VERIFY_NO_CONTENT_INFO;
- }
-
-+ // We're expecting this to be a PKCS#7 signedData content info.
-+ if (NSS_CMSContentInfo_GetContentTypeTag(cinfo)
-+ != SEC_OID_PKCS7_SIGNED_DATA) {
-+ return NS_ERROR_CMS_VERIFY_NO_CONTENT_INFO;
-+ }
-+
- // signedData is non-owning
- NSSCMSSignedData* signedData =
- static_cast<NSSCMSSignedData*>(NSS_CMSContentInfo_GetContent(cinfo));
-diff --git security/nss.symbols security/nss.symbols
-index 626fc64d96f9..517a577a8de4 100644
---- security/nss.symbols
-+++ security/nss.symbols
-@@ -181,6 +181,7 @@ HASH_ResultLenByOidTag
- HASH_Update
- NSSBase64_EncodeItem_Util
- NSS_CMSContentInfo_GetContent
-+NSS_CMSContentInfo_GetContentTypeTag
- NSS_CMSContentInfo_SetContent_Data
- NSS_CMSContentInfo_SetContent_EnvelopedData
- NSS_CMSContentInfo_SetContent_SignedData
diff --git a/www/firefox/files/patch-bug1412252 b/www/firefox/files/patch-bug1412252
deleted file mode 100644
index 9e89513a47cc..000000000000
--- a/www/firefox/files/patch-bug1412252
+++ /dev/null
@@ -1,42 +0,0 @@
-commit 4bb201af8ede
-Author: Emilio Cobos Álvarez <emilio@crisal.io>
-Date: Sun Oct 29 17:39:20 2017 -0400
-
- Bug 1412252 - Only fetch mPresShell after flushing the relevant content pres shell. r=bz, a=ritu
-
- MozReview-Commit-ID: BkcYtu2MsNs
-
- --HG--
- extra : rebase_source : aaf4e69af1cfb4e6becd491f3f4a6e4924cb307a
- extra : source : 044406030675adf7dfdb0317fca3852fa1ea3ff7
----
- layout/style/nsComputedDOMStyle.cpp | 10 +++++-----
- 1 file changed, 5 insertions(+), 5 deletions(-)
-
-diff --git layout/style/nsComputedDOMStyle.cpp layout/style/nsComputedDOMStyle.cpp
-index 1aa07e691d4a..1eb9fbebdc8d 100644
---- layout/style/nsComputedDOMStyle.cpp
-+++ layout/style/nsComputedDOMStyle.cpp
-@@ -826,17 +826,17 @@ nsComputedDOMStyle::UpdateCurrentStyleSources(bool aNeedsLayoutFlush)
- mFlushedPendingReflows = aNeedsLayoutFlush;
- #endif
-
-+ nsCOMPtr<nsIPresShell> presShellForContent = GetPresShellForContent(mContent);
-+ if (presShellForContent && presShellForContent != document->GetShell()) {
-+ presShellForContent->FlushPendingNotifications(FlushType::Style);
-+ }
-+
- mPresShell = document->GetShell();
- if (!mPresShell || !mPresShell->GetPresContext()) {
- ClearStyleContext();
- return;
- }
-
-- nsCOMPtr<nsIPresShell> presShellForContent = GetPresShellForContent(mContent);
-- if (presShellForContent && presShellForContent != mPresShell) {
-- presShellForContent->FlushPendingNotifications(FlushType::Style);
-- }
--
- // We need to use GetUndisplayedRestyleGeneration instead of
- // GetRestyleGeneration, because the caching of mStyleContext is an
- // optimization that is useful only for displayed elements.
diff --git a/www/firefox/files/patch-bug847568 b/www/firefox/files/patch-bug847568
index c2c40cc26b26..ed16b8d7caac 100644
--- a/www/firefox/files/patch-bug847568
+++ b/www/firefox/files/patch-bug847568
@@ -261,7 +261,7 @@ index 9297e4d6f501..d8e273887e4b 100644
+option('--with-system-harfbuzz',
+ help="Use system harfbuzz (located with pkgconfig)")
+
-+system_harfbuzz = pkg_check_modules('MOZ_HARFBUZZ', 'harfbuzz >= 1.4.7',
++system_harfbuzz = pkg_check_modules('MOZ_HARFBUZZ', 'harfbuzz >= 1.5.1',
+ when='--with-system-harfbuzz')
+
+set_config('MOZ_SYSTEM_HARFBUZZ', depends_if(system_harfbuzz)(lambda _: True))
diff --git a/www/firefox/files/patch-build-pgo-profileserver.py b/www/firefox/files/patch-build-pgo-profileserver.py
index 31a3a0889c0a..aec54852f395 100644
--- a/www/firefox/files/patch-build-pgo-profileserver.py
+++ b/www/firefox/files/patch-build-pgo-profileserver.py
@@ -1,11 +1,11 @@
---- build/pgo/profileserver.py.orig 2011-02-24 21:49:47.000000000 +0100
-+++ build/pgo/profileserver.py 2011-02-24 21:50:30.000000000 +0100
-@@ -59,7 +59,7 @@ if __name__ == '__main__':
- env["MOZ_JAR_LOG_FILE"] = os.path.abspath(jarlog)
- print "jarlog: %s" % env["MOZ_JAR_LOG_FILE"]
+--- build/pgo/profileserver.py.orig 2017-09-15 04:15:39 UTC
++++ build/pgo/profileserver.py
+@@ -87,7 +87,7 @@ if __name__ == '__main__':
+ env["MOZ_JAR_LOG_FILE"] = os.path.abspath(jarlog)
+ print "jarlog: %s" % env["MOZ_JAR_LOG_FILE"]
-- cmdargs = ["http://localhost:%d/index.html" % PORT]
-+ cmdargs = ["http://127.0.0.1:%d/index.html" % PORT]
- runner = FirefoxRunner(profile=profile,
- binary=build.get_binary_path(where="staged-package"),
- cmdargs=cmdargs,
+- cmdargs = ["http://localhost:%d/index.html" % PORT]
++ cmdargs = ["http://127.0.0.1:%d/index.html" % PORT]
+ runner = FirefoxRunner(profile=profile,
+ binary=build.get_binary_path(
+ where="staged-package"),
diff --git a/www/firefox/files/patch-servo17934 b/www/firefox/files/patch-servo17934
deleted file mode 100644
index c6e4193a1f6c..000000000000
--- a/www/firefox/files/patch-servo17934
+++ /dev/null
@@ -1,53 +0,0 @@
-commit 4cbdfa028752
-Author: Manish Goregaokar <manishsmail@gmail.com>
-Date: Tue Aug 1 12:57:42 2017 -0500
-
- servo: Merge #17934 - Remove doc comment on statement (from Manishearth:doc-comment); r=canaltinova
-
- rustc warns about these now
-
- Source-Repo: https://github.com/servo/servo
- Source-Revision: b49311c65a083a9b8eb03741bf7ea980b64f1e03
-
- --HG--
- extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
- extra : subtree_revision : 6b3c7d7f4ffeb9e271c52d418cda42cac5dd378d
----
- servo/components/style/values/specified/image.rs | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git servo/components/style/values/specified/image.rs servo/components/style/values/specified/image.rs
-index 37ed00ccf443..687c6f17d432 100644
---- servo/components/style/values/specified/image.rs
-+++ servo/components/style/values/specified/image.rs
-@@ -686,14 +686,14 @@ impl LineDirection {
- input.try(|i| {
- let to_ident = i.try(|i| i.expect_ident_matching("to"));
- match *compat_mode {
-- /// `to` keyword is mandatory in modern syntax.
-+ // `to` keyword is mandatory in modern syntax.
- CompatMode::Modern => to_ident?,
- // Fall back to Modern compatibility mode in case there is a `to` keyword.
- // According to Gecko, `-moz-linear-gradient(to ...)` should serialize like
- // `linear-gradient(to ...)`.
- CompatMode::Moz if to_ident.is_ok() => *compat_mode = CompatMode::Modern,
-- /// There is no `to` keyword in webkit prefixed syntax. If it's consumed,
-- /// parsing should throw an error.
-+ // There is no `to` keyword in webkit prefixed syntax. If it's consumed,
-+ // parsing should throw an error.
- CompatMode::WebKit if to_ident.is_ok() => {
- return Err(SelectorParseError::UnexpectedIdent("to".into()).into())
- },
-diff --git servo/components/style/properties/gecko.mako.rs servo/components/style/properties/gecko.mako.rs
-index 37ed00ccf443..687c6f17d432 100644
---- servo/components/style/properties/gecko.mako.rs
-+++ servo/components/style/properties/gecko.mako.rs
-@@ -2081,7 +2081,7 @@ fn static_assert() {
- return (parent_size, parent_unconstrained_size)
- }
-
-- /// XXXManishearth this should also handle text zoom
-+ // XXXManishearth this should also handle text zoom
- let min = Au(parent.gecko.mScriptMinSize);
-
- let scale = (parent.gecko.mScriptSizeMultiplier as f32).powi(delta as i32);
diff --git a/www/firefox/files/patch-servo17969 b/www/firefox/files/patch-servo17969
deleted file mode 100644
index ca16754b987f..000000000000
--- a/www/firefox/files/patch-servo17969
+++ /dev/null
@@ -1,110 +0,0 @@
-commit 9f5c1f2e4b5b
-Author: Manish Goregaokar <manishsmail@gmail.com>
-Date: Thu Aug 3 16:27:12 2017 -0500
-
- servo: Merge #17969 - Update stylo code to work on nightly (from Manishearth:rustup); r=emilio
-
- r=emilio https://bugzilla.mozilla.org/show_bug.cgi?id=1386887
-
- Source-Repo: https://github.com/servo/servo
- Source-Revision: 7cee7d7fcc4194e410fa8a308a77d37ac452778a
-
- --HG--
- extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
- extra : subtree_revision : d9c874ebcfa1e64c86265d0ed2e5cff65d9133be
----
- servo/components/style/gecko/generated/bindings.rs | 12 +++++++++---
- servo/components/style/gecko/wrapper.rs | 7 ++++++-
- servo/ports/geckolib/glue.rs | 3 ++-
- 3 files changed, 17 insertions(+), 5 deletions(-)
-
-diff --git servo/components/style/gecko/generated/bindings.rs servo/components/style/gecko/generated/bindings.rs
-index e46bdfe1e1ea..b6703ab95bf7 100644
---- servo/components/style/gecko/generated/bindings.rs
-+++ servo/components/style/gecko/generated/bindings.rs
-@@ -8,6 +8,7 @@ type nsAString_internal = nsAString;
- pub type ServoStyleContextBorrowed<'a> = &'a ::properties::ComputedValues;
- pub type ServoStyleContextBorrowedOrNull<'a> = Option<&'a ::properties::ComputedValues>;
- pub type ServoComputedDataBorrowed<'a> = &'a ServoComputedData;
-+pub type RawServoAnimationValueTableBorrowed<'a> = &'a ();
- use gecko_bindings::structs::mozilla::css::GridTemplateAreasValue;
- use gecko_bindings::structs::mozilla::css::ErrorReporter;
- use gecko_bindings::structs::mozilla::css::ImageValue;
-@@ -37,7 +38,7 @@ use gecko_bindings::structs::RawServoStyleRule;
- use gecko_bindings::structs::RawGeckoPresContext;
- use gecko_bindings::structs::RawGeckoPresContextOwned;
- use gecko_bindings::structs::RawGeckoStyleAnimationList;
--use gecko_bindings::structs::RawGeckoStyleChildrenIteratorBorrowedMut;
-+use gecko_bindings::structs::RawGeckoStyleChildrenIterator;
- use gecko_bindings::structs::RawGeckoServoStyleRuleList;
- use gecko_bindings::structs::RawGeckoURLExtraData;
- use gecko_bindings::structs::RawGeckoXBLBinding;
-@@ -320,6 +321,10 @@ pub type RawGeckoServoAnimationValueListBorrowed<'a> = &'a RawGeckoServoAnimatio
- pub type RawGeckoServoAnimationValueListBorrowedOrNull<'a> = Option<&'a RawGeckoServoAnimationValueList>;
- pub type RawGeckoServoAnimationValueListBorrowedMut<'a> = &'a mut RawGeckoServoAnimationValueList;
- pub type RawGeckoServoAnimationValueListBorrowedMutOrNull<'a> = Option<&'a mut RawGeckoServoAnimationValueList>;
-+pub type RawGeckoStyleChildrenIteratorBorrowed<'a> = &'a RawGeckoStyleChildrenIterator;
-+pub type RawGeckoStyleChildrenIteratorBorrowedOrNull<'a> = Option<&'a RawGeckoStyleChildrenIterator>;
-+pub type RawGeckoStyleChildrenIteratorBorrowedMut<'a> = &'a mut RawGeckoStyleChildrenIterator;
-+pub type RawGeckoStyleChildrenIteratorBorrowedMutOrNull<'a> = Option<&'a mut RawGeckoStyleChildrenIterator>;
- pub type ServoCssRulesStrong = ::gecko_bindings::sugar::ownership::Strong<ServoCssRules>;
- pub type ServoCssRulesBorrowed<'a> = &'a ServoCssRules;
- pub type ServoCssRulesBorrowedOrNull<'a> = Option<&'a ServoCssRules>;
-@@ -840,7 +845,7 @@ extern "C" {
- }
- extern "C" {
- pub fn Gecko_AnimationGetBaseStyle(aBaseStyles:
-- *mut ::std::os::raw::c_void,
-+ RawServoAnimationValueTableBorrowed,
- aProperty: nsCSSPropertyID)
- -> RawServoAnimationValueBorrowedOrNull;
- }
-@@ -2602,7 +2607,8 @@ extern "C" {
- extern "C" {
- pub fn Servo_AnimationCompose(animation_values:
- RawServoAnimationValueMapBorrowedMut,
-- base_values: *mut ::std::os::raw::c_void,
-+ base_values:
-+ RawServoAnimationValueTableBorrowed,
- property: nsCSSPropertyID,
- animation_segment:
- RawGeckoAnimationPropertySegmentBorrowed,
-diff --git servo/components/style/gecko/wrapper.rs servo/components/style/gecko/wrapper.rs
-index dae898692313..6d62f54951cc 100644
---- servo/components/style/gecko/wrapper.rs
-+++ servo/components/style/gecko/wrapper.rs
-@@ -387,7 +387,12 @@ impl<'a> Iterator for GeckoChildrenIterator<'a> {
- curr
- },
- GeckoChildrenIterator::GeckoIterator(ref mut it) => unsafe {
-- Gecko_GetNextStyleChild(it).map(GeckoNode)
-+ // We do this unsafe lengthening of the lifetime here because
-+ // structs::StyleChildrenIterator is actually StyleChildrenIterator<'a>,
-+ // however we can't express this easily with bindgen, and it would
-+ // introduce functions with two input lifetimes into bindgen,
-+ // which would be out of scope for elision.
-+ Gecko_GetNextStyleChild(&mut * (it as *mut _)).map(GeckoNode)
- }
- }
- }
-diff --git servo/ports/geckolib/glue.rs servo/ports/geckolib/glue.rs
-index 367d24ff87b2..e69959f3710b 100644
---- servo/ports/geckolib/glue.rs
-+++ servo/ports/geckolib/glue.rs
-@@ -59,6 +59,7 @@ use style::gecko_bindings::bindings::RawGeckoServoStyleRuleListBorrowedMut;
- use style::gecko_bindings::bindings::RawServoAnimationValueBorrowed;
- use style::gecko_bindings::bindings::RawServoAnimationValueMapBorrowedMut;
- use style::gecko_bindings::bindings::RawServoAnimationValueStrong;
-+use style::gecko_bindings::bindings::RawServoAnimationValueTableBorrowed;
- use style::gecko_bindings::bindings::RawServoStyleRuleBorrowed;
- use style::gecko_bindings::bindings::ServoStyleContextBorrowedOrNull;
- use style::gecko_bindings::bindings::nsTArrayBorrowed_uintptr_t;
-@@ -374,7 +375,7 @@ pub extern "C" fn Servo_AnimationValues_ComputeDistance(from: RawServoAnimationV
-
- #[no_mangle]
- pub extern "C" fn Servo_AnimationCompose(raw_value_map: RawServoAnimationValueMapBorrowedMut,
-- base_values: *mut ::std::os::raw::c_void,
-+ base_values: RawServoAnimationValueTableBorrowed,
- css_property: nsCSSPropertyID,
- segment: RawGeckoAnimationPropertySegmentBorrowed,
- last_segment: RawGeckoAnimationPropertySegmentBorrowed,
diff --git a/www/firefox/files/patch-servo18046 b/www/firefox/files/patch-servo18046
deleted file mode 100644
index 574e91f8831f..000000000000
--- a/www/firefox/files/patch-servo18046
+++ /dev/null
@@ -1,763 +0,0 @@
-commit ea9c8db790e4
-Author: Simon Sapin <simon.sapin@exyr.org>
-Date: Tue Aug 15 07:31:04 2017 -0500
-
- servo: Merge #18046 - Upgrade to rustc 1.21.0-nightly (13d94d5fa 2017-08-10) (from servo:rustup); r=emilio
-
- Source-Repo: https://github.com/servo/servo
- Source-Revision: 7d9b82b9efa7b10a2e34d93df5ac535d99518f7a
-
- --HG--
- extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
- extra : subtree_revision : e1b3d113c3edaea3c4c07f8b206f2e02922e3caf
----
- servo/Cargo.lock | 6 +++---
- servo/components/devtools/lib.rs | 2 +-
- servo/components/layout/animation.rs | 2 +-
- servo/components/layout/construct.rs | 6 +++---
- servo/components/layout/display_list_builder.rs | 2 +-
- servo/components/layout/flex.rs | 6 +++---
- servo/components/layout/inline.rs | 4 ++--
- servo/components/layout/sequential.rs | 2 +-
- servo/components/layout/table_cell.rs | 2 +-
- servo/components/layout/text.rs | 2 +-
- servo/components/net/cookie_storage.rs | 2 +-
- servo/components/profile/heartbeats.rs | 4 ++--
- servo/components/script/dom/bindings/js.rs | 4 ++--
- servo/components/script/dom/cssstyledeclaration.rs | 8 ++++----
- servo/components/script/dom/cssstylerule.rs | 2 +-
- servo/components/script/dom/document.rs | 12 ++++++------
- servo/components/script/dom/medialist.rs | 4 ++--
- servo/components/script/dom/range.rs | 4 ++--
- .../script/dom/servoparser/async_html.rs | 4 ++--
- servo/components/script/dom/url.rs | 4 ++--
- servo/components/script/dom/vrdisplay.rs | 2 +-
- .../components/script/dom/webglrenderingcontext.rs | 2 +-
- servo/components/script/dom/xmlhttprequest.rs | 2 +-
- servo/components/script/lib.rs | 1 -
- .../script_plugins/unrooted_must_root.rs | 22 +++++++++++++++-------
- servo/components/selectors/matching.rs | 2 +-
- servo/components/selectors/parser.rs | 2 +-
- .../style/invalidation/element/invalidator.rs | 2 +-
- servo/components/style/matching.rs | 2 +-
- .../components/style/properties/properties.mako.rs | 2 +-
- servo/components/style/style_adjuster.rs | 2 +-
- servo/components/style/style_resolver.rs | 2 +-
- servo/components/style/stylesheets/rule_list.rs | 2 +-
- servo/components/style/stylesheets/rule_parser.rs | 2 +-
- .../components/style/stylesheets/rules_iterator.rs | 2 +-
- servo/components/style/values/animated/color.rs | 2 +-
- servo/components/style/values/computed/border.rs | 2 +-
- servo/components/webdriver_server/lib.rs | 2 +-
- servo/rust-commit-hash | 2 +-
- servo/tests/unit/style/stylist.rs | 13 -------------
- 40 files changed, 73 insertions(+), 79 deletions(-)
-
-diff --git servo/Cargo.lock servo/Cargo.lock
-index 50dd6e1a785a..2aa7bd8ea3dd 100644
---- servo/Cargo.lock
-+++ servo/Cargo.lock
-@@ -3577,7 +3577,7 @@ version = "0.1.4"
- source = "registry+https://github.com/rust-lang/crates.io-index"
- dependencies = [
- "error-chain 0.10.0 (registry+https://github.com/rust-lang/crates.io-index)",
-- "xcb 0.7.6 (registry+https://github.com/rust-lang/crates.io-index)",
-+ "xcb 0.7.7 (registry+https://github.com/rust-lang/crates.io-index)",
- ]
-
- [[package]]
-@@ -3592,7 +3592,7 @@ dependencies = [
-
- [[package]]
- name = "xcb"
--version = "0.7.6"
-+version = "0.7.7"
- source = "registry+https://github.com/rust-lang/crates.io-index"
- dependencies = [
- "libc 0.2.23 (registry+https://github.com/rust-lang/crates.io-index)",
-@@ -3918,7 +3918,7 @@ dependencies = [
- "checksum x11 2.14.0 (registry+https://github.com/rust-lang/crates.io-index)" = "db27c597c187da52194a4b8232e7d869503911aab9ff726fefb76d7a830f78ed"
- "checksum x11-clipboard 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "731230b8edcbb9d99247105e4c9ec0a538594d50ad68d2afa8662195f9db2973"
- "checksum x11-dl 2.14.0 (registry+https://github.com/rust-lang/crates.io-index)" = "326c500cdc166fd7c70dd8c8a829cd5c0ce7be5a5d98c25817de2b9bdc67faf8"
--"checksum xcb 0.7.6 (registry+https://github.com/rust-lang/crates.io-index)" = "63e3a849b73e4e1905e4f4d48f1750429bc86ea9f473632ab382a6f69ecb6b33"
-+"checksum xcb 0.7.7 (registry+https://github.com/rust-lang/crates.io-index)" = "7cede38417fcdf2f0a9d8abf1cea1c1b066320a8a316e9583a0d717c334fafb2"
- "checksum xdg 2.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "a66b7c2281ebde13cf4391d70d4c7e5946c3c25e72a7b859ca8f677dcd0b0c61"
- "checksum xi-unicode 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "12ea8eda4b1eb72f02d148402e23832d56a33f55d8c1b2d5bcdde91d79d47cb1"
- "checksum xml-rs 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)" = "7ec6c39eaa68382c8e31e35239402c0a9489d4141a8ceb0c716099a0b515b562"
-diff --git servo/components/devtools/lib.rs servo/components/devtools/lib.rs
-index d5a2764a7102..6a25696eaed7 100644
---- servo/components/devtools/lib.rs
-+++ servo/components/devtools/lib.rs
-@@ -306,7 +306,7 @@ fn run_server(sender: Sender<DevtoolsControlMsg>,
- columnNumber: console_message.columnNumber,
- },
- };
-- for mut stream in &mut *console_actor.streams.borrow_mut() {
-+ for stream in &mut *console_actor.streams.borrow_mut() {
- stream.write_json_packet(&msg);
- }
- }
-diff --git servo/components/layout/animation.rs servo/components/layout/animation.rs
-index e4a2782c1271..ebbba82fcc6a 100644
---- servo/components/layout/animation.rs
-+++ servo/components/layout/animation.rs
-@@ -39,7 +39,7 @@ pub fn update_animation_state(constellation_chan: &IpcSender<ConstellationMsg>,
- // run.
- if let Some(ref mut animations) = running_animations.get_mut(node) {
- // TODO: This being linear is probably not optimal.
-- for mut anim in animations.iter_mut() {
-+ for anim in animations.iter_mut() {
- if let Animation::Keyframes(_, ref anim_name, ref mut anim_state) = *anim {
- if *name == *anim_name {
- debug!("update_animation_state: Found other animation {}", name);
-diff --git servo/components/layout/construct.rs servo/components/layout/construct.rs
-index c863219941e4..7ef391b42183 100644
---- servo/components/layout/construct.rs
-+++ servo/components/layout/construct.rs
-@@ -1921,7 +1921,7 @@ impl Legalizer {
- /// true for anonymous block children of flex flows.
- fn try_to_add_child(&mut self, context: &SharedStyleContext, parent: &mut FlowRef, child: &mut FlowRef)
- -> bool {
-- let mut parent = self.stack.last_mut().unwrap_or(parent);
-+ let parent = self.stack.last_mut().unwrap_or(parent);
- let (parent_class, child_class) = (parent.class(), child.class());
- match (parent_class, child_class) {
- (FlowClass::TableWrapper, FlowClass::Table) |
-@@ -1962,7 +1962,7 @@ impl Legalizer {
- } else {
- IS_BLOCK_FLEX_ITEM
- };
-- let mut block = FlowRef::deref_mut(&mut block_wrapper).as_mut_block();
-+ let block = FlowRef::deref_mut(&mut block_wrapper).as_mut_block();
- block.base.flags.insert(MARGINS_CANNOT_COLLAPSE);
- block.fragment.flags.insert(flag);
- }
-@@ -1979,7 +1979,7 @@ impl Legalizer {
- } else {
- IS_BLOCK_FLEX_ITEM
- };
-- let mut block = FlowRef::deref_mut(child).as_mut_block();
-+ let block = FlowRef::deref_mut(child).as_mut_block();
- block.base.flags.insert(MARGINS_CANNOT_COLLAPSE);
- block.fragment.flags.insert(flag);
- }
-diff --git servo/components/layout/display_list_builder.rs servo/components/layout/display_list_builder.rs
-index f8b26899b57d..783574afd2a3 100644
---- servo/components/layout/display_list_builder.rs
-+++ servo/components/layout/display_list_builder.rs
-@@ -2718,7 +2718,7 @@ impl InlineFlowDisplayListBuilding for InlineFlow {
- self.base.scroll_root_id = Some(state.current_scroll_root_id);
- self.base.clip = state.clip_stack.last().cloned().unwrap_or_else(max_rect);
-
-- for mut fragment in self.fragments.fragments.iter_mut() {
-+ for fragment in self.fragments.fragments.iter_mut() {
- let previous_containing_block_scroll_root_id = state.containing_block_scroll_root_id;
- if establishes_containing_block_for_absolute(fragment.style.get_box().position) {
- state.containing_block_scroll_root_id = state.current_scroll_root_id;
-diff --git servo/components/layout/flex.rs servo/components/layout/flex.rs
-index 353c939f58b9..d79580f8cd0d 100644
---- servo/components/layout/flex.rs
-+++ servo/components/layout/flex.rs
-@@ -415,7 +415,7 @@ impl FlexFlow {
-
- let items = &mut self.items[start..];
- let mut children = self.block_flow.base.children.random_access_mut();
-- for mut item in items {
-+ for item in items {
- let kid = children.get(item.index);
- item.init_sizes(kid, container_size, self.main_mode);
- let outer_main_size = item.outer_main_size(kid, self.main_mode);
-@@ -607,7 +607,7 @@ impl FlexFlow {
-
- let mut children = self.block_flow.base.children.random_access_mut();
- for item in items.iter_mut() {
-- let mut block = children.get(item.index).as_mut_block();
-+ let block = children.get(item.index).as_mut_block();
-
- block.base.block_container_writing_mode = container_mode;
- block.base.block_container_inline_size = inline_size;
-@@ -659,7 +659,7 @@ impl FlexFlow {
-
- let mut children = self.block_flow.base.children.random_access_mut();
- for item in &mut self.items {
-- let mut base = flow::mut_base(children.get(item.index));
-+ let base = flow::mut_base(children.get(item.index));
- if !self.main_reverse {
- base.position.start.b = cur_b;
- cur_b = cur_b + base.position.size.block;
-diff --git servo/components/layout/inline.rs servo/components/layout/inline.rs
-index d5813d9bea22..10e091c3c66d 100644
---- servo/components/layout/inline.rs
-+++ servo/components/layout/inline.rs
-@@ -435,7 +435,7 @@ impl LineBreaker {
- return
- }
- let last_fragment_index = self.pending_line.range.end() - FragmentIndex(1);
-- let mut fragment = &mut self.new_fragments[last_fragment_index.get() as usize];
-+ let fragment = &mut self.new_fragments[last_fragment_index.get() as usize];
-
- let old_fragment_inline_size = fragment.border_box.size.inline;
-
-@@ -1047,7 +1047,7 @@ impl InlineFlow {
- let space_per_expansion_opportunity = slack_inline_size / expansion_opportunities as i32;
- for fragment_index in line.range.each_index() {
- let fragment = fragments.get_mut(fragment_index.to_usize());
-- let mut scanned_text_fragment_info = match fragment.specific {
-+ let scanned_text_fragment_info = match fragment.specific {
- SpecificFragmentInfo::ScannedText(ref mut info) if !info.range.is_empty() => info,
- _ => continue
- };
-diff --git servo/components/layout/sequential.rs servo/components/layout/sequential.rs
-index f6f8ce429e4f..4986ebb6c852 100644
---- servo/components/layout/sequential.rs
-+++ servo/components/layout/sequential.rs
-@@ -133,7 +133,7 @@ pub fn store_overflow(layout_context: &LayoutContext, flow: &mut Flow) {
- return;
- }
-
-- for mut kid in flow::mut_base(flow).child_iter_mut() {
-+ for kid in flow::mut_base(flow).child_iter_mut() {
- store_overflow(layout_context, kid);
- }
-
-diff --git servo/components/layout/table_cell.rs servo/components/layout/table_cell.rs
-index 7ef02e28db65..fd807989b463 100644
---- servo/components/layout/table_cell.rs
-+++ servo/components/layout/table_cell.rs
-@@ -136,7 +136,7 @@ impl TableCellFlow {
- }
-
- for kid in flow::mut_base(self).children.iter_mut() {
-- let mut kid_base = flow::mut_base(kid);
-+ let kid_base = flow::mut_base(kid);
- if !kid_base.flags.contains(IS_ABSOLUTELY_POSITIONED) {
- kid_base.position.start.b += offset
- }
-diff --git servo/components/layout/text.rs servo/components/layout/text.rs
-index 6e1c7b2a43a1..9a207a2bb84e 100644
---- servo/components/layout/text.rs
-+++ servo/components/layout/text.rs
-@@ -460,7 +460,7 @@ fn split_first_fragment_at_newline_if_necessary(fragments: &mut LinkedList<Fragm
- }
-
- let new_fragment = {
-- let mut first_fragment = fragments.front_mut().unwrap();
-+ let first_fragment = fragments.front_mut().unwrap();
- let string_before;
- let selection_before;
- {
-diff --git servo/components/net/cookie_storage.rs servo/components/net/cookie_storage.rs
-index f255f57b56d2..b3147ef4dd32 100644
---- servo/components/net/cookie_storage.rs
-+++ servo/components/net/cookie_storage.rs
-@@ -103,7 +103,7 @@ impl CookieStorage {
-
- // Step 12
- let domain = reg_host(&cookie.cookie.domain().as_ref().unwrap_or(&""));
-- let mut cookies = self.cookies_map.entry(domain).or_insert(vec![]);
-+ let cookies = self.cookies_map.entry(domain).or_insert(vec![]);
-
- if cookies.len() == self.max_per_host {
- let old_len = cookies.len();
-diff --git servo/components/profile/heartbeats.rs servo/components/profile/heartbeats.rs
-index 4661dad61836..0d474fe3a111 100644
---- servo/components/profile/heartbeats.rs
-+++ servo/components/profile/heartbeats.rs
-@@ -33,7 +33,7 @@ pub fn cleanup() {
- )
- );
- if let Some(mut hbs) = hbs_opt_box {
-- for (_, mut v) in hbs.iter_mut() {
-+ for (_, v) in hbs.iter_mut() {
- // log any remaining heartbeat records before dropping
- log_heartbeat_records(v);
- }
-@@ -65,7 +65,7 @@ pub fn maybe_heartbeat(category: &ProfilerCategory,
- if !(*hbs_ptr).contains_key(category) {
- maybe_create_heartbeat(&mut (*hbs_ptr), category.clone());
- }
-- if let Some(mut h) = (*hbs_ptr).get_mut(category) {
-+ if let Some(h) = (*hbs_ptr).get_mut(category) {
- (*h).heartbeat(0, 1, start_time, end_time, start_energy, end_energy);
- }
- }
-diff --git servo/components/script/dom/bindings/js.rs servo/components/script/dom/bindings/js.rs
-index 975ddeda13b0..abfd9f47eff1 100644
---- servo/components/script/dom/bindings/js.rs
-+++ servo/components/script/dom/bindings/js.rs
-@@ -469,7 +469,7 @@ impl RootCollection {
- /// Start tracking a stack-based root
- unsafe fn root(&self, untracked_reflector: *const Reflector) {
- debug_assert!(thread_state::get().is_script());
-- let mut roots = &mut *self.roots.get();
-+ let roots = &mut *self.roots.get();
- roots.push(untracked_reflector);
- assert!(!(*untracked_reflector).get_jsobject().is_null())
- }
-@@ -479,7 +479,7 @@ impl RootCollection {
- assert!(!tracked_reflector.is_null());
- assert!(!(*tracked_reflector).get_jsobject().is_null());
- debug_assert!(thread_state::get().is_script());
-- let mut roots = &mut *self.roots.get();
-+ let roots = &mut *self.roots.get();
- match roots.iter().rposition(|r| *r == tracked_reflector) {
- Some(idx) => {
- roots.remove(idx);
-diff --git servo/components/script/dom/cssstyledeclaration.rs servo/components/script/dom/cssstyledeclaration.rs
-index 0732c9af9e45..ddf085b34913 100644
---- servo/components/script/dom/cssstyledeclaration.rs
-+++ servo/components/script/dom/cssstyledeclaration.rs
-@@ -238,7 +238,7 @@ impl CSSStyleDeclaration {
- return Err(Error::NoModificationAllowed);
- }
-
-- self.owner.mutate_associated_block(|ref mut pdb, mut changed| {
-+ self.owner.mutate_associated_block(|pdb, changed| {
- if value.is_empty() {
- // Step 3
- *changed = pdb.remove_property(&id);
-@@ -360,7 +360,7 @@ impl CSSStyleDeclarationMethods for CSSStyleDeclaration {
- _ => return Ok(()),
- };
-
-- self.owner.mutate_associated_block(|ref mut pdb, mut changed| {
-+ self.owner.mutate_associated_block(|pdb, changed| {
- // Step 5 & 6
- *changed = pdb.set_importance(&id, importance);
- });
-@@ -388,7 +388,7 @@ impl CSSStyleDeclarationMethods for CSSStyleDeclaration {
- };
-
- let mut string = String::new();
-- self.owner.mutate_associated_block(|mut pdb, mut changed| {
-+ self.owner.mutate_associated_block(|pdb, changed| {
- pdb.property_value_to_css(&id, &mut string).unwrap();
- *changed = pdb.remove_property(&id);
- });
-@@ -438,7 +438,7 @@ impl CSSStyleDeclarationMethods for CSSStyleDeclaration {
- }
-
- let quirks_mode = window.Document().quirks_mode();
-- self.owner.mutate_associated_block(|mut pdb, mut _changed| {
-+ self.owner.mutate_associated_block(|pdb, _changed| {
- // Step 3
- *pdb = parse_style_attribute(&value,
- &self.owner.base_url(),
-diff --git servo/components/script/dom/cssstylerule.rs servo/components/script/dom/cssstylerule.rs
-index ea121ef900a9..12e9cdcc8694 100644
---- servo/components/script/dom/cssstylerule.rs
-+++ servo/components/script/dom/cssstylerule.rs
-@@ -99,7 +99,7 @@ impl CSSStyleRuleMethods for CSSStyleRule {
- if let Ok(mut s) = SelectorList::parse(&parser, &mut css_parser) {
- // This mirrors what we do in CSSStyleOwner::mutate_associated_block.
- let mut guard = self.cssrule.shared_lock().write();
-- let mut stylerule = self.stylerule.write_with(&mut guard);
-+ let stylerule = self.stylerule.write_with(&mut guard);
- mem::swap(&mut stylerule.selectors, &mut s);
- // It seems like we will want to avoid having to invalidate all
- // stylesheets eventually!
-diff --git servo/components/script/dom/document.rs servo/components/script/dom/document.rs
-index 90ea06fbe7b4..71bb02eaa364 100644
---- servo/components/script/dom/document.rs
-+++ servo/components/script/dom/document.rs
-@@ -633,7 +633,7 @@ impl Document {
- // reset_form_owner_for_listeners -> reset_form_owner -> GetElementById
- {
- let mut id_map = self.id_map.borrow_mut();
-- let mut elements = id_map.entry(id.clone()).or_insert(Vec::new());
-+ let elements = id_map.entry(id.clone()).or_insert(Vec::new());
- elements.insert_pre_order(element, root.r().upcast::<Node>());
- }
- self.reset_form_owner_for_listeners(&id);
-@@ -642,7 +642,7 @@ impl Document {
- pub fn register_form_id_listener<T: ?Sized + FormControl>(&self, id: DOMString, listener: &T) {
- let mut map = self.form_id_listener_map.borrow_mut();
- let listener = listener.to_element();
-- let mut set = map.entry(Atom::from(id)).or_insert(HashSet::new());
-+ let set = map.entry(Atom::from(id)).or_insert(HashSet::new());
- set.insert(JS::from_ref(listener));
- }
-
-@@ -1572,7 +1572,7 @@ impl Document {
- /// https://html.spec.whatwg.org/multipage/#dom-window-cancelanimationframe
- pub fn cancel_animation_frame(&self, ident: u32) {
- let mut list = self.animation_frame_list.borrow_mut();
-- if let Some(mut pair) = list.iter_mut().find(|pair| pair.0 == ident) {
-+ if let Some(pair) = list.iter_mut().find(|pair| pair.0 == ident) {
- pair.1 = None;
- }
- }
-@@ -2399,7 +2399,7 @@ impl Document {
- if entry.snapshot.is_none() {
- entry.snapshot = Some(Snapshot::new(el.html_element_in_html_document()));
- }
-- let mut snapshot = entry.snapshot.as_mut().unwrap();
-+ let snapshot = entry.snapshot.as_mut().unwrap();
- if snapshot.state.is_none() {
- snapshot.state = Some(el.state());
- }
-@@ -2426,7 +2426,7 @@ impl Document {
- entry.hint.insert(RESTYLE_SELF);
- }
-
-- let mut snapshot = entry.snapshot.as_mut().unwrap();
-+ let snapshot = entry.snapshot.as_mut().unwrap();
- if attr.local_name() == &local_name!("id") {
- snapshot.id_changed = true;
- } else if attr.local_name() == &local_name!("class") {
-@@ -4028,7 +4028,7 @@ impl PendingInOrderScriptVec {
-
- fn loaded(&self, element: &HTMLScriptElement, result: ScriptResult) {
- let mut scripts = self.scripts.borrow_mut();
-- let mut entry = scripts.iter_mut().find(|entry| &*entry.element == element).unwrap();
-+ let entry = scripts.iter_mut().find(|entry| &*entry.element == element).unwrap();
- entry.loaded(result);
- }
-
-diff --git servo/components/script/dom/medialist.rs servo/components/script/dom/medialist.rs
-index 0064d0445095..ae20f5aa0422 100644
---- servo/components/script/dom/medialist.rs
-+++ servo/components/script/dom/medialist.rs
-@@ -63,7 +63,7 @@ impl MediaListMethods for MediaList {
- // https://drafts.csswg.org/cssom/#dom-medialist-mediatext
- fn SetMediaText(&self, value: DOMString) {
- let mut guard = self.shared_lock().write();
-- let mut media_queries = self.media_queries.write_with(&mut guard);
-+ let media_queries = self.media_queries.write_with(&mut guard);
- // Step 2
- if value.is_empty() {
- // Step 1
-@@ -154,7 +154,7 @@ impl MediaListMethods for MediaList {
- // Step 3
- let m_serialized = m.unwrap().to_css_string();
- let mut guard = self.shared_lock().write();
-- let mut media_list = self.media_queries.write_with(&mut guard);
-+ let media_list = self.media_queries.write_with(&mut guard);
- let new_vec = media_list.media_queries.drain(..)
- .filter(|q| m_serialized != q.to_css_string())
- .collect();
-diff --git servo/components/script/dom/range.rs servo/components/script/dom/range.rs
-index fa849a0fc1a2..1e65caedc9dd 100644
---- servo/components/script/dom/range.rs
-+++ servo/components/script/dom/range.rs
-@@ -1049,7 +1049,7 @@ impl WeakRangeVec {
- let offset = context.index();
- let parent = context.parent;
- unsafe {
-- let mut ranges = &mut *self.cell.get();
-+ let ranges = &mut *self.cell.get();
-
- ranges.update(|entry| {
- let range = entry.root().unwrap();
-@@ -1076,7 +1076,7 @@ impl WeakRangeVec {
- }
-
- unsafe {
-- let mut ranges = &mut *self.cell.get();
-+ let ranges = &mut *self.cell.get();
-
- ranges.update(|entry| {
- let range = entry.root().unwrap();
-diff --git servo/components/script/dom/servoparser/async_html.rs servo/components/script/dom/servoparser/async_html.rs
-index 59411fda1c73..70d2008f49f6 100644
---- servo/components/script/dom/servoparser/async_html.rs
-+++ servo/components/script/dom/servoparser/async_html.rs
-@@ -568,7 +568,7 @@ impl TreeSink for Sink {
- }
- let node = self.new_parse_node();
- {
-- let mut data = self.get_parse_node_data_mut(&target.id);
-+ let data = self.get_parse_node_data_mut(&target.id);
- data.contents = Some(node.clone());
- }
- self.send_op(ParseOperation::GetTemplateContents { target: target.id, contents: node.id });
-@@ -596,7 +596,7 @@ impl TreeSink for Sink {
- let mut node = self.new_parse_node();
- node.qual_name = Some(name.clone());
- {
-- let mut node_data = self.get_parse_node_data_mut(&node.id);
-+ let node_data = self.get_parse_node_data_mut(&node.id);
- node_data.is_integration_point = html_attrs.iter()
- .any(|attr| {
- let attr_value = &String::from(attr.value.clone());
-diff --git servo/components/script/dom/url.rs servo/components/script/dom/url.rs
-index a02a735638fc..41de4dcc0c72 100644
---- servo/components/script/dom/url.rs
-+++ servo/components/script/dom/url.rs
-@@ -96,8 +96,8 @@ impl URL {
-
- // https://w3c.github.io/FileAPI/#dfn-createObjectURL
- pub fn CreateObjectURL(global: &GlobalScope, blob: &Blob) -> DOMString {
-- /// XXX: Second field is an unicode-serialized Origin, it is a temporary workaround
-- /// and should not be trusted. See issue https://github.com/servo/servo/issues/11722
-+ // XXX: Second field is an unicode-serialized Origin, it is a temporary workaround
-+ // and should not be trusted. See issue https://github.com/servo/servo/issues/11722
- let origin = get_blob_origin(&global.get_url());
-
- let id = blob.get_blob_url_id();
-diff --git servo/components/script/dom/vrdisplay.rs servo/components/script/dom/vrdisplay.rs
-index 3f73a577fad7..54f06fb928f2 100644
---- servo/components/script/dom/vrdisplay.rs
-+++ servo/components/script/dom/vrdisplay.rs
-@@ -268,7 +268,7 @@ impl VRDisplayMethods for VRDisplay {
- fn CancelAnimationFrame(&self, handle: u32) {
- if self.presenting.get() {
- let mut list = self.raf_callback_list.borrow_mut();
-- if let Some(mut pair) = list.iter_mut().find(|pair| pair.0 == handle) {
-+ if let Some(pair) = list.iter_mut().find(|pair| pair.0 == handle) {
- pair.1 = None;
- }
- } else {
-diff --git servo/components/script/dom/webglrenderingcontext.rs servo/components/script/dom/webglrenderingcontext.rs
-index 73d4ddba1b90..62c92b42785c 100644
---- servo/components/script/dom/webglrenderingcontext.rs
-+++ servo/components/script/dom/webglrenderingcontext.rs
-@@ -2434,7 +2434,7 @@ impl WebGLRenderingContextMethods for WebGLRenderingContext {
- }
-
- typedarray!(in(cx) let mut pixels_data: ArrayBufferView = pixels);
-- let (array_type, mut data) = match { pixels_data.as_mut() } {
-+ let (array_type, data) = match { pixels_data.as_mut() } {
- Ok(data) => (data.get_array_type(), data.as_mut_slice()),
- Err(_) => return Err(Error::Type("Not an ArrayBufferView".to_owned())),
- };
-diff --git servo/components/script/dom/xmlhttprequest.rs servo/components/script/dom/xmlhttprequest.rs
-index 6ed2dda1851f..e6652d79d706 100644
---- servo/components/script/dom/xmlhttprequest.rs
-+++ servo/components/script/dom/xmlhttprequest.rs
-@@ -627,7 +627,7 @@ impl XMLHttpRequestMethods for XMLHttpRequest {
-
- if !content_type_set {
- let ct = request.headers.get_mut::<ContentType>();
-- if let Some(mut ct) = ct {
-+ if let Some(ct) = ct {
- if let Some(encoding) = encoding {
- for param in &mut (ct.0).2 {
- if param.0 == MimeAttr::Charset {
-diff --git servo/components/script/lib.rs servo/components/script/lib.rs
-index e1a1ab592cb7..5824d6f2e490 100644
---- servo/components/script/lib.rs
-+++ servo/components/script/lib.rs
-@@ -9,7 +9,6 @@
- #![feature(mpsc_select)]
- #![feature(nonzero)]
- #![feature(on_unimplemented)]
--#![feature(option_entry)]
- #![feature(plugin)]
- #![feature(proc_macro)]
- #![feature(stmt_expr_attributes)]
-diff --git servo/components/script_plugins/unrooted_must_root.rs servo/components/script_plugins/unrooted_must_root.rs
-index 5dbd2b1a3bdd..f3f5e60ab62a 100644
---- servo/components/script_plugins/unrooted_must_root.rs
-+++ servo/components/script_plugins/unrooted_must_root.rs
-@@ -182,7 +182,7 @@ impl<'a, 'b, 'tcx> visit::Visitor<'tcx> for FnDefVisitor<'a, 'b, 'tcx> {
- }
-
- match expr.node {
-- /// Trait casts from #[must_root] types are not allowed
-+ // Trait casts from #[must_root] types are not allowed
- hir::ExprCast(ref subexpr, _) => require_rooted(cx, self.in_new_function, &*subexpr),
- // This catches assignments... the main point of this would be to catch mutable
- // references to `JS<T>`.
-@@ -206,13 +206,21 @@ impl<'a, 'b, 'tcx> visit::Visitor<'tcx> for FnDefVisitor<'a, 'b, 'tcx> {
- fn visit_pat(&mut self, pat: &'tcx hir::Pat) {
- let cx = self.cx;
-
-- if let hir::PatKind::Binding(hir::BindingMode::BindByValue(_), _, _, _) = pat.node {
-- let ty = cx.tables.pat_ty(pat);
-- if is_unrooted_ty(cx, ty, self.in_new_function) {
-- cx.span_lint(UNROOTED_MUST_ROOT,
-- pat.span,
-- &format!("Expression of type {:?} must be rooted", ty))
-+ // We want to detect pattern bindings that move a value onto the stack.
-+ // When "default binding modes" https://github.com/rust-lang/rust/issues/42640
-+ // are implemented, the `Unannotated` case could cause false-positives.
-+ // These should be fixable by adding an explicit `ref`.
-+ match pat.node {
-+ hir::PatKind::Binding(hir::BindingAnnotation::Unannotated, _, _, _) |
-+ hir::PatKind::Binding(hir::BindingAnnotation::Mutable, _, _, _) => {
-+ let ty = cx.tables.pat_ty(pat);
-+ if is_unrooted_ty(cx, ty, self.in_new_function) {
-+ cx.span_lint(UNROOTED_MUST_ROOT,
-+ pat.span,
-+ &format!("Expression of type {:?} must be rooted", ty))
-+ }
- }
-+ _ => {}
- }
-
- visit::walk_pat(self, pat);
-diff --git servo/components/selectors/matching.rs servo/components/selectors/matching.rs
-index 7bd9814d26fb..8f6b2fa6aa54 100644
---- servo/components/selectors/matching.rs
-+++ servo/components/selectors/matching.rs
-@@ -458,7 +458,7 @@ where
- /// Matches a complex selector.
- pub fn matches_complex_selector<E, F>(mut iter: SelectorIter<E::Impl>,
- element: &E,
-- mut context: &mut LocalMatchingContext<E::Impl>,
-+ context: &mut LocalMatchingContext<E::Impl>,
- flags_setter: &mut F)
- -> bool
- where E: Element,
-diff --git servo/components/selectors/parser.rs servo/components/selectors/parser.rs
-index 490399ce38ce..6b2c1f2b4e86 100644
---- servo/components/selectors/parser.rs
-+++ servo/components/selectors/parser.rs
-@@ -1464,7 +1464,7 @@ fn parse_negation<'i, 't, P, E, Impl>(parser: &P,
- fn parse_compound_selector<'i, 't, P, E, Impl>(
- parser: &P,
- input: &mut CssParser<'i, 't>,
-- mut builder: &mut SelectorBuilder<Impl>)
-+ builder: &mut SelectorBuilder<Impl>)
- -> Result<bool, ParseError<'i, SelectorParseError<'i, E>>>
- where P: Parser<'i, Impl=Impl, Error=E>, Impl: SelectorImpl
- {
-diff --git servo/components/style/invalidation/element/invalidator.rs servo/components/style/invalidation/element/invalidator.rs
-index 848c5cd13dc8..b8510ba3169b 100644
---- servo/components/style/invalidation/element/invalidator.rs
-+++ servo/components/style/invalidation/element/invalidator.rs
-@@ -154,7 +154,7 @@ impl<'a, 'b: 'a, E> TreeStyleInvalidator<'a, 'b, E>
- trace!(" > visitedness change, force subtree restyle");
- // We can't just return here because there may also be attribute
- // changes as well that imply additional hints.
-- let mut data = self.data.as_mut().unwrap();
-+ let data = self.data.as_mut().unwrap();
- data.restyle.hint.insert(RestyleHint::restyle_subtree());
- }
-
-diff --git servo/components/style/matching.rs servo/components/style/matching.rs
-index b62bc54bf768..f58d7cd123e6 100644
---- servo/components/style/matching.rs
-+++ servo/components/style/matching.rs
-@@ -440,7 +440,7 @@ pub trait MatchMethods : TElement {
- fn finish_restyle(
- &self,
- context: &mut StyleContext<Self>,
-- mut data: &mut ElementData,
-+ data: &mut ElementData,
- mut new_styles: ElementStyles,
- important_rules_changed: bool,
- ) -> ChildCascadeRequirement {
-diff --git servo/components/style/properties/properties.mako.rs servo/components/style/properties/properties.mako.rs
-index d98e173db5ba..81ff00fb6d5e 100644
---- servo/components/style/properties/properties.mako.rs
-+++ servo/components/style/properties/properties.mako.rs
-@@ -3364,7 +3364,7 @@ pub fn modify_border_style_for_inline_sides(style: &mut Arc<ComputedValues>,
- return;
- }
- }
-- let mut style = Arc::make_mut(style);
-+ let style = Arc::make_mut(style);
- let border = Arc::make_mut(&mut style.border);
- match side {
- PhysicalSide::Left => {
-diff --git servo/components/style/style_adjuster.rs servo/components/style/style_adjuster.rs
-index 366641ebe0bc..6e51fa74072a 100644
---- servo/components/style/style_adjuster.rs
-+++ servo/components/style/style_adjuster.rs
-@@ -269,7 +269,7 @@ impl<'a, 'b: 'a> StyleAdjuster<'a, 'b> {
-
- if overflow_x != original_overflow_x ||
- overflow_y != original_overflow_y {
-- let mut box_style = self.style.mutate_box();
-+ let box_style = self.style.mutate_box();
- box_style.set_overflow_x(overflow_x);
- box_style.set_overflow_y(overflow_y);
- }
-diff --git servo/components/style/style_resolver.rs servo/components/style/style_resolver.rs
-index cf512c4fbdd2..3fc1d57cc8f7 100644
---- servo/components/style/style_resolver.rs
-+++ servo/components/style/style_resolver.rs
-@@ -247,7 +247,7 @@ where
- Some(&*primary_style.style)
- };
-
-- for (i, mut inputs) in pseudo_array.iter_mut().enumerate() {
-+ for (i, inputs) in pseudo_array.iter_mut().enumerate() {
- if let Some(inputs) = inputs.take() {
- let pseudo = PseudoElement::from_eager_index(i);
- pseudo_styles.set(
-diff --git servo/components/style/stylesheets/rule_list.rs servo/components/style/stylesheets/rule_list.rs
-index 82e78015400d..14b3dc5e7696 100644
---- servo/components/style/stylesheets/rule_list.rs
-+++ servo/components/style/stylesheets/rule_list.rs
-@@ -150,7 +150,7 @@ impl CssRulesHelpers for RawOffsetArc<Locked<CssRules>> {
-
- {
- let mut write_guard = lock.write();
-- let mut rules = self.write_with(&mut write_guard);
-+ let rules = self.write_with(&mut write_guard);
- // Step 5
- // Computes the maximum allowed parser state at a given index.
- let rev_state = rules.0.get(index).map_or(State::Body, CssRule::rule_state);
-diff --git servo/components/style/stylesheets/rule_parser.rs servo/components/style/stylesheets/rule_parser.rs
-index 007d7e11026e..f0d224e498a7 100644
---- servo/components/style/stylesheets/rule_parser.rs
-+++ servo/components/style/stylesheets/rule_parser.rs
-@@ -209,7 +209,7 @@ impl<'a, 'i> AtRuleParser<'i> for TopLevelRuleParser<'a> {
- let id = register_namespace(&url)
- .map_err(|()| StyleParseError::UnspecifiedError)?;
-
-- let mut namespaces = self.namespaces.as_mut().unwrap();
-+ let namespaces = self.namespaces.as_mut().unwrap();
-
- let opt_prefix = if let Ok(prefix) = prefix_result {
- let prefix = Prefix::from(prefix.as_ref());
-diff --git servo/components/style/stylesheets/rules_iterator.rs servo/components/style/stylesheets/rules_iterator.rs
-index 95a3ab8b3885..65e1b637ae52 100644
---- servo/components/style/stylesheets/rules_iterator.rs
-+++ servo/components/style/stylesheets/rules_iterator.rs
-@@ -70,7 +70,7 @@ impl<'a, 'b, C> Iterator for RulesIterator<'a, 'b, C>
-
- let rule;
- let sub_iter = {
-- let mut nested_iter = self.stack.last_mut().unwrap();
-+ let nested_iter = self.stack.last_mut().unwrap();
- rule = match nested_iter.next() {
- Some(r) => r,
- None => {
-diff --git servo/components/webdriver_server/lib.rs servo/components/webdriver_server/lib.rs
-index bd2f667f9892..28a4885f0d41 100644
---- servo/components/webdriver_server/lib.rs
-+++ servo/components/webdriver_server/lib.rs
-@@ -702,7 +702,7 @@ impl Handler {
- fn handle_set_timeouts(&mut self,
- parameters: &TimeoutsParameters)
- -> WebDriverResult<WebDriverResponse> {
-- let mut session = self.session
-+ let session = self.session
- .as_mut()
- .ok_or(WebDriverError::new(ErrorStatus::SessionNotCreated, ""))?;
-
-diff --git servo/rust-commit-hash servo/rust-commit-hash
-index d4f08fe97644..a08d23cd1a71 100644
---- servo/rust-commit-hash
-+++ servo/rust-commit-hash
-@@ -1 +1 @@
--599be0d18f4c6ddf36366d2a5a2ca6dc65886896
-+13d94d5fa8129a34f5c77a1bcd76983f5aed2434
-diff --git servo/tests/unit/style/stylist.rs servo/tests/unit/style/stylist.rs
-index da9a9478957a..52067b501788 100644
---- servo/tests/unit/style/stylist.rs
-+++ servo/tests/unit/style/stylist.rs
-@@ -51,19 +51,6 @@ fn get_mock_rules(css_selectors: &[&str]) -> (Vec<Vec<Rule>>, SharedRwLock) {
- }).collect(), shared_lock)
- }
-
--fn get_mock_map(selectors: &[&str]) -> (SelectorMap<Rule>, SharedRwLock) {
-- let mut map = SelectorMap::<Rule>::new();
-- let (selector_rules, shared_lock) = get_mock_rules(selectors);
--
-- for rules in selector_rules.into_iter() {
-- for rule in rules.into_iter() {
-- map.insert(rule, QuirksMode::NoQuirks)
-- }
-- }
--
-- (map, shared_lock)
--}
--
- fn parse_selectors(selectors: &[&str]) -> Vec<Selector<SelectorImpl>> {
- selectors.iter()
- .map(|x| SelectorParser::parse_author_origin_no_namespace(x).unwrap().0
diff --git a/www/firefox/files/patch-servo18126 b/www/firefox/files/patch-servo18126
deleted file mode 100644
index ec5e77ad94e0..000000000000
--- a/www/firefox/files/patch-servo18126
+++ /dev/null
@@ -1,232 +0,0 @@
-commit f0acf27d189d
-Author: Simon Sapin <simon.sapin@exyr.org>
-Date: Thu Aug 17 11:05:32 2017 -0500
-
- servo: Merge #18126 - geckolib: Fix some warnings (treated as error) new in Rust Nigthly (from servo:glow-fox); r=emilio
-
- Source-Repo: https://github.com/servo/servo
- Source-Revision: cc86ca2bcdec5e89ee5279085ea38db63ef41af9
-
- --HG--
- extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
- extra : subtree_revision : 0586dbc81f1411c89821605a6dae4ebd0af8f0d5
----
- servo/components/style/gecko/conversions.rs | 2 +-
- servo/components/style/gecko/wrapper.rs | 2 +-
- .../style/gecko_bindings/sugar/ns_t_array.rs | 4 ++--
- servo/components/style/properties/gecko.mako.rs | 18 +++++++++---------
- servo/components/style/style_adjuster.rs | 4 ++--
- servo/ports/geckolib/glue.rs | 12 ++++++------
- 6 files changed, 21 insertions(+), 21 deletions(-)
-
-diff --git servo/components/style/gecko/conversions.rs servo/components/style/gecko/conversions.rs
-index 8f3fb6bf2d0f..51015997c5c1 100644
---- servo/components/style/gecko/conversions.rs
-+++ servo/components/style/gecko/conversions.rs
-@@ -348,7 +348,7 @@ impl nsStyleImage {
- // NB: stops are guaranteed to be none in the gecko side by
- // default.
-
-- let mut gecko_stop = unsafe {
-+ let gecko_stop = unsafe {
- &mut (*gecko_gradient).mStops[index]
- };
- let mut coord = nsStyleCoord::null();
-diff --git servo/components/style/gecko/wrapper.rs servo/components/style/gecko/wrapper.rs
-index 034dd94590e2..c402ddaf15bd 100644
---- servo/components/style/gecko/wrapper.rs
-+++ servo/components/style/gecko/wrapper.rs
-@@ -424,7 +424,7 @@ impl<'lb> GeckoXBLBinding<'lb> {
- }
- }
-
-- fn each_xbl_stylist<F>(self, mut f: &mut F)
-+ fn each_xbl_stylist<F>(self, f: &mut F)
- where
- F: FnMut(&Stylist),
- {
-diff --git servo/components/style/gecko_bindings/sugar/ns_t_array.rs servo/components/style/gecko_bindings/sugar/ns_t_array.rs
-index 6bc389702f54..068e10ddea1b 100644
---- servo/components/style/gecko_bindings/sugar/ns_t_array.rs
-+++ servo/components/style/gecko_bindings/sugar/ns_t_array.rs
-@@ -90,7 +90,7 @@ impl<T> nsTArray<T> {
- // this can leak
- debug_assert!(len >= self.len() as u32);
- self.ensure_capacity(len as usize);
-- let mut header = self.header_mut();
-+ let header = self.header_mut();
- header.mLength = len;
- }
-
-@@ -99,7 +99,7 @@ impl<T> nsTArray<T> {
- /// This will not leak since it only works on POD types (and thus doesn't assert)
- pub unsafe fn set_len_pod(&mut self, len: u32) where T: Copy {
- self.ensure_capacity(len as usize);
-- let mut header = unsafe { self.header_mut() };
-+ let header = unsafe { self.header_mut() };
- header.mLength = len;
- }
- }
-diff --git servo/components/style/properties/gecko.mako.rs servo/components/style/properties/gecko.mako.rs
-index 9a2ab2135fc5..bc41ef139af5 100644
---- servo/components/style/properties/gecko.mako.rs
-+++ servo/components/style/properties/gecko.mako.rs
-@@ -4136,14 +4136,14 @@ fn static_assert() {
- fn init_shadow(filter: &mut nsStyleFilter) -> &mut nsCSSShadowArray {
- unsafe {
- let ref mut union = filter.__bindgen_anon_1;
-- let mut shadow_array: &mut *mut nsCSSShadowArray = union.mDropShadow.as_mut();
-+ let shadow_array: &mut *mut nsCSSShadowArray = union.mDropShadow.as_mut();
- *shadow_array = Gecko_NewCSSShadowArray(1);
-
- &mut **shadow_array
- }
- }
-
-- let mut gecko_shadow = init_shadow(gecko_filter);
-+ let gecko_shadow = init_shadow(gecko_filter);
- gecko_shadow.mArray[0].set_from_simple_shadow(shadow);
- },
- Url(ref url) => {
-@@ -4665,14 +4665,14 @@ fn static_assert() {
- unsafe {
- // We have to be very careful to avoid a copy here!
- let ref mut union = ${ident}.__bindgen_anon_1;
-- let mut shape: &mut *mut StyleBasicShape = union.mBasicShape.as_mut();
-+ let shape: &mut *mut StyleBasicShape = union.mBasicShape.as_mut();
- *shape = Gecko_NewBasicShape(ty);
- &mut **shape
- }
- }
- match servo_shape {
- BasicShape::Inset(inset) => {
-- let mut shape = init_shape(${ident}, StyleBasicShapeType::Inset);
-+ let shape = init_shape(${ident}, StyleBasicShapeType::Inset);
- unsafe { shape.mCoordinates.set_len(4) };
-
- // set_len() can't call constructors, so the coordinates
-@@ -4694,7 +4694,7 @@ fn static_assert() {
- set_corners_from_radius(inset.round, &mut shape.mRadius);
- }
- BasicShape::Circle(circ) => {
-- let mut shape = init_shape(${ident}, StyleBasicShapeType::Circle);
-+ let shape = init_shape(${ident}, StyleBasicShapeType::Circle);
- unsafe { shape.mCoordinates.set_len(1) };
- shape.mCoordinates[0].leaky_set_null();
- circ.radius.to_gecko_style_coord(&mut shape.mCoordinates[0]);
-@@ -4702,7 +4702,7 @@ fn static_assert() {
- shape.mPosition = circ.position.into();
- }
- BasicShape::Ellipse(el) => {
-- let mut shape = init_shape(${ident}, StyleBasicShapeType::Ellipse);
-+ let shape = init_shape(${ident}, StyleBasicShapeType::Ellipse);
- unsafe { shape.mCoordinates.set_len(2) };
- shape.mCoordinates[0].leaky_set_null();
- el.semiaxis_x.to_gecko_style_coord(&mut shape.mCoordinates[0]);
-@@ -4712,7 +4712,7 @@ fn static_assert() {
- shape.mPosition = el.position.into();
- }
- BasicShape::Polygon(poly) => {
-- let mut shape = init_shape(${ident}, StyleBasicShapeType::Polygon);
-+ let shape = init_shape(${ident}, StyleBasicShapeType::Polygon);
- unsafe {
- shape.mCoordinates.set_len(poly.coordinates.len() as u32 * 2);
- }
-@@ -4797,7 +4797,7 @@ clip-path
- bindings::Gecko_nsStyleSVG_SetDashArrayLength(&mut self.gecko, v.len() as u32);
- }
-
-- for (mut gecko, servo) in self.gecko.mStrokeDasharray.iter_mut().zip(v) {
-+ for (gecko, servo) in self.gecko.mStrokeDasharray.iter_mut().zip(v) {
- match servo {
- Either::First(number) => gecko.set_value(CoordDataValue::Factor(number)),
- Either::Second(lop) => gecko.set(lop),
-@@ -4885,7 +4885,7 @@ clip-path
- }
-
- self.gecko.mContextPropsBits = 0;
-- for (mut gecko, servo) in self.gecko.mContextProps.iter_mut().zip(v) {
-+ for (gecko, servo) in self.gecko.mContextProps.iter_mut().zip(v) {
- if servo.0 == atom!("fill") {
- self.gecko.mContextPropsBits |= structs::NS_STYLE_CONTEXT_PROPERTY_FILL as u8;
- } else if servo.0 == atom!("stroke") {
-diff --git servo/components/style/style_adjuster.rs servo/components/style/style_adjuster.rs
-index 03b15916b237..366641ebe0bc 100644
---- servo/components/style/style_adjuster.rs
-+++ servo/components/style/style_adjuster.rs
-@@ -167,7 +167,7 @@ impl<'a, 'b: 'a> StyleAdjuster<'a, 'b> {
- // When 'contain: paint', update overflow from 'visible' to 'clip'.
- if self.style.get_box().clone_contain().contains(contain::PAINT) {
- if self.style.get_box().clone_overflow_x() == overflow::visible {
-- let mut box_style = self.style.mutate_box();
-+ let box_style = self.style.mutate_box();
- box_style.set_overflow_x(overflow::_moz_hidden_unscrollable);
- box_style.set_overflow_y(overflow::_moz_hidden_unscrollable);
- }
-@@ -182,7 +182,7 @@ impl<'a, 'b: 'a> StyleAdjuster<'a, 'b> {
- use properties::longhands::font_style::computed_value::T as font_style;
- use properties::longhands::font_weight::computed_value::T as font_weight;
- if self.style.get_font().clone__moz_math_variant() != moz_math_variant::none {
-- let mut font_style = self.style.mutate_font();
-+ let font_style = self.style.mutate_font();
- // Sadly we don't have a nice name for the computed value
- // of "font-weight: normal".
- font_style.set_font_weight(font_weight::normal());
-diff --git servo/ports/geckolib/glue.rs servo/ports/geckolib/glue.rs
-index 977728286fc3..fa09bee29553 100644
---- servo/ports/geckolib/glue.rs
-+++ servo/ports/geckolib/glue.rs
-@@ -815,7 +815,7 @@ pub extern "C" fn Servo_StyleSet_AppendStyleSheet(
- ) {
- let global_style_data = &*GLOBAL_STYLE_DATA;
- let mut data = PerDocumentStyleData::from_ffi(raw_data).borrow_mut();
-- let mut data = &mut *data;
-+ let data = &mut *data;
- let guard = global_style_data.shared_lock.read();
- data.stylesheets.append_stylesheet(
- &data.stylist,
-@@ -867,7 +867,7 @@ pub extern "C" fn Servo_StyleSet_PrependStyleSheet(
- ) {
- let global_style_data = &*GLOBAL_STYLE_DATA;
- let mut data = PerDocumentStyleData::from_ffi(raw_data).borrow_mut();
-- let mut data = &mut *data;
-+ let data = &mut *data;
- let guard = global_style_data.shared_lock.read();
- data.stylesheets.prepend_stylesheet(
- &data.stylist,
-@@ -885,7 +885,7 @@ pub extern "C" fn Servo_StyleSet_InsertStyleSheetBefore(
- ) {
- let global_style_data = &*GLOBAL_STYLE_DATA;
- let mut data = PerDocumentStyleData::from_ffi(raw_data).borrow_mut();
-- let mut data = &mut *data;
-+ let data = &mut *data;
- let guard = global_style_data.shared_lock.read();
- data.stylesheets.insert_stylesheet_before(
- &data.stylist,
-@@ -903,7 +903,7 @@ pub extern "C" fn Servo_StyleSet_RemoveStyleSheet(
- ) {
- let global_style_data = &*GLOBAL_STYLE_DATA;
- let mut data = PerDocumentStyleData::from_ffi(raw_data).borrow_mut();
-- let mut data = &mut *data;
-+ let data = &mut *data;
- let guard = global_style_data.shared_lock.read();
- data.stylesheets.remove_stylesheet(
- &data.stylist,
-@@ -1274,7 +1274,7 @@ pub extern "C" fn Servo_StyleRule_GetSpecificityAtIndex(
- specificity: *mut u64
- ) {
- read_locked_arc(rule, |rule: &StyleRule| {
-- let mut specificity = unsafe { specificity.as_mut().unwrap() };
-+ let specificity = unsafe { specificity.as_mut().unwrap() };
- let index = index as usize;
- if index >= rule.selectors.0.len() {
- *specificity = 0;
-@@ -2775,7 +2775,7 @@ pub extern "C" fn Servo_NoteExplicitHints(element: RawGeckoElementBorrowed,
- pub extern "C" fn Servo_TakeChangeHint(element: RawGeckoElementBorrowed,
- was_restyled: *mut bool) -> nsChangeHint
- {
-- let mut was_restyled = unsafe { was_restyled.as_mut().unwrap() };
-+ let was_restyled = unsafe { was_restyled.as_mut().unwrap() };
- let element = GeckoElement(element);
-
- let damage = match element.mutate_data() {