Index: branches/2018Q2/www/waterfox/Makefile =================================================================== --- branches/2018Q2/www/waterfox/Makefile (revision 466931) +++ branches/2018Q2/www/waterfox/Makefile (revision 466932) @@ -1,74 +1,74 @@ # $FreeBSD$ PORTNAME= waterfox DISTVERSION= 56.1.0 -PORTREVISION= 7 +PORTREVISION= 8 CATEGORIES= www ipv6 MAINTAINER= jbeich@FreeBSD.org COMMENT= Distilled fork of Firefox DEPRECATED= Temporary experiment EXPIRATION_DATE=2018-05-16 BUILD_DEPENDS= nspr>=4.16:devel/nspr \ nss>=3.32.1:security/nss \ icu>=59.1,1:devel/icu \ libevent>=2.1.8:devel/libevent \ harfbuzz>=1.4.7: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 \ ${PYTHON_PKGNAMEPREFIX}sqlite3>0:databases/py-sqlite3@${PY_FLAVOR} \ v4l_compat>0:multimedia/v4l_compat \ autoconf-2.13:devel/autoconf213 \ yasm:devel/yasm \ zip:archivers/zip # soundtouch>=1.9.0:audio/soundtouch \ LIB_DEPENDS= libv4l2.so:multimedia/libv4l USE_GITHUB= yes GH_ACCOUNT= MrAlex94 GH_PROJECT= Waterfox USE_GECKO= gecko MOZ_PKGCONFIG_FILES= # empty USE_MOZILLA= -soundtouch MOZILLA_NAME= Waterfox USE_GL= gl WATERFOX_ICON= ${MOZILLA}.png WATERFOX_ICON_SRC= ${PREFIX}/lib/${MOZILLA}/browser/chrome/icons/default/default256.png WATERFOX_DESKTOP= ${MOZSRC}/taskcluster/docker/firefox-snap/firefox.desktop MOZ_OPTIONS= --enable-application=browser \ --with-app-name=${MOZILLA} \ --with-app-basename=${MOZILLA_NAME} \ --with-distribution-id=org.${MOZILLA}project OPTIONS_DEFAULT= BUNDLED_CAIRO .include "${.CURDIR}/../../www/firefox/Makefile.options" post-patch: @${REINPLACE_CMD} -e 's/%u/%U/' -e '/X-MultipleArgs/d' \ -e 's/firefox/${MOZILLA}/' \ -e 's/Firefox/${MOZILLA_NAME}/' \ ${WATERFOX_DESKTOP} @${REINPLACE_CMD} -e 's|%%LOCALBASE%%|${LOCALBASE}|g' \ ${WRKSRC}/browser/app/nsBrowserApp.cpp pre-configure: (cd ${WRKSRC} && ${LOCALBASE}/bin/autoconf-2.13) (cd ${WRKSRC}/js/src/ && ${LOCALBASE}/bin/autoconf-2.13) post-install: ${INSTALL_DATA} ${WATERFOX_DESKTOP} \ ${STAGEDIR}${PREFIX}/share/applications/${MOZILLA}.desktop ${MKDIR} ${STAGEDIR}${PREFIX}/share/pixmaps ${LN} -sf ${WATERFOX_ICON_SRC} ${STAGEDIR}${PREFIX}/share/pixmaps/${WATERFOX_ICON} .include Index: branches/2018Q2/www/waterfox/files/patch-bug1203273 =================================================================== --- branches/2018Q2/www/waterfox/files/patch-bug1203273 (nonexistent) +++ branches/2018Q2/www/waterfox/files/patch-bug1203273 (revision 466932) @@ -0,0 +1,68 @@ +commit 18bd60050c9c +Author: Jon Coppeard +Date: Tue Mar 20 10:19:37 2018 +0000 + + Bug 1203273 - Add a canary to check gray buffers are valid. r=sfink, a=RyanVM + + --HG-- + extra : source : b1dacff4b3744f303f04ad9f53c670608af8b17a +--- + js/src/gc/RootMarking.cpp | 23 ++++++++++++++++++++++- + 1 file changed, 22 insertions(+), 1 deletion(-) + +diff --git js/src/gc/RootMarking.cpp js/src/gc/RootMarking.cpp +index 384edb9fdd2a..a5c408b687b9 100644 +--- js/src/gc/RootMarking.cpp ++++ js/src/gc/RootMarking.cpp +@@ -460,6 +460,7 @@ class BufferGrayRootsTracer final : public JS::CallbackTracer + {} + + bool failed() const { return bufferingGrayRootsFailed; } ++ void setFailed() { bufferingGrayRootsFailed = true; } + + #ifdef DEBUG + TracerKind getTracerKind() const override { return TracerKind::GrayBuffering; } +@@ -477,6 +478,9 @@ js::IsBufferGrayRootsTracer(JSTracer* trc) + } + #endif + ++// A canary value used to check the gray buffer contents are valid. ++static Cell* const GrayBufferCanary = reinterpret_cast(0x47726179); // "Gray" ++ + void + js::gc::GCRuntime::bufferGrayRoots() + { +@@ -490,6 +494,12 @@ js::gc::GCRuntime::bufferGrayRoots() + if (JSTraceDataOp op = grayRootTracer.op) + (*op)(&grayBufferer, grayRootTracer.data); + ++ // Push a canary value onto the end of the list. ++ for (GCZonesIter zone(rt); !zone.done(); zone.next()) { ++ if (!zone->gcGrayRoots().empty() && !zone->gcGrayRoots().append(GrayBufferCanary)) ++ grayBufferer.setFailed(); ++ } ++ + // Propagate the failure flag from the marker to the runtime. + if (grayBufferer.failed()) { + grayBufferState = GrayBufferState::Failed; +@@ -531,8 +541,19 @@ GCRuntime::markBufferedGrayRoots(JS::Zone* zone) + MOZ_ASSERT(grayBufferState == GrayBufferState::Okay); + MOZ_ASSERT(zone->isGCMarkingGray() || zone->isGCCompacting()); + +- for (auto cell : zone->gcGrayRoots()) ++ auto& roots = zone->gcGrayRoots(); ++ if (roots.empty()) ++ return; ++ ++ // Check for and remove canary value. ++ MOZ_RELEASE_ASSERT(roots.length() > 1); ++ MOZ_RELEASE_ASSERT(roots.back() == GrayBufferCanary); ++ roots.popBack(); ++ ++ for (auto cell : zone->gcGrayRoots()) { ++ MOZ_ASSERT(IsCellPointerValid(cell)); + TraceManuallyBarrieredGenericPointerEdge(&marker, &cell, "buffered gray root"); ++ } + } + + void Property changes on: branches/2018Q2/www/waterfox/files/patch-bug1203273 ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: branches/2018Q2/www/waterfox/files/patch-bug1427480 =================================================================== --- branches/2018Q2/www/waterfox/files/patch-bug1427480 (nonexistent) +++ branches/2018Q2/www/waterfox/files/patch-bug1427480 (revision 466932) @@ -0,0 +1,40 @@ +commit ce0b5382185d +Author: Jonathan Kew +Date: Tue Mar 20 18:02:18 2018 +0000 + + Bug 1427480 - Increase the MAX_FONT_SIZE limit applied in cairo_ft_font to match the gfxFont size limit. r=lsalzman, a=RyanVM + + --HG-- + extra : source : 74ffac5bc156c537ff4b1cc3d98dbb2c61b3127d + extra : histedit_source : ee241f50804b89b4d545aedc5503cf0cb7c767f7 +--- + gfx/cairo/cairo/src/cairo-ft-font.c | 2 +- + gfx/cairo/max-font-size.patch | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git gfx/cairo/cairo/src/cairo-ft-font.c gfx/cairo/cairo/src/cairo-ft-font.c +index 9d0e4951a28e..56430740a20c 100644 +--- gfx/cairo/cairo/src/cairo-ft-font.c ++++ gfx/cairo/cairo/src/cairo-ft-font.c +@@ -103,7 +103,7 @@ static setLcdFilterFunc setLcdFilter; + #define MAX_OPEN_FACES 10 + /* This is the maximum font size we allow to be passed to FT_Set_Char_Size + */ +-#define MAX_FONT_SIZE 1000 ++#define MAX_FONT_SIZE 2000 + + extern FT_Face mozilla_NewFTFace(FT_Library aFTLibrary, const char* aFileName, int aFaceIndex); + extern FT_Face mozilla_NewFTFaceFromData(FT_Library aFTLibrary, const uint8_t* aData, size_t aDataSize, int aFaceIndex); +diff --git gfx/cairo/max-font-size.patch gfx/cairo/max-font-size.patch +index 99be23906ab4..efa54cef646a 100644 +--- gfx/cairo/max-font-size.patch ++++ gfx/cairo/max-font-size.patch +@@ -8,7 +8,7 @@ diff --git a/gfx/cairo/cairo/src/cairo-ft-font.c b/gfx/cairo/cairo/src/cairo-ft- + + + +/* This is the maximum font size we allow to be passed to FT_Set_Char_Size + + */ +-+#define MAX_FONT_SIZE 1000 +++#define MAX_FONT_SIZE 2000 + + /* + * The simple 2x2 matrix is converted into separate scale and shape Property changes on: branches/2018Q2/www/waterfox/files/patch-bug1427480 ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: branches/2018Q2/www/waterfox/files/patch-bug1432793 =================================================================== --- branches/2018Q2/www/waterfox/files/patch-bug1432793 (nonexistent) +++ branches/2018Q2/www/waterfox/files/patch-bug1432793 (revision 466932) @@ -0,0 +1,218 @@ +commit b1ccdd29d2a5 +Author: Dan Minor +Date: Wed Mar 28 11:07:54 2018 -0400 + + Bug 1432793 - Force screensharing simulcast to one layer and stop generating layers once an odd width and height are found. r=bwc, a=RyanVM + + This limits screensharing simulcast to a single layer. When window sharing, our + source video can have arbitrary dimensions. If one of those dimensions ends up + being odd, the aspect ratio of the smaller layer will not match the aspect ratio + of the odd sized layer, causing a runtime assertion failure and crash. + + It is not sufficient to prevent the creation of odd sized layers in + CreateEncoderStreams because the user can resize the window while it is being + shared, which will cause a fatal assertion prior to the streams being recreated. + + When switching back from window sharing to camera, a call to + CreateEncoderStreams will occur with resolutions matching the dimensions of + the window that was just shared. To prevent a crash, this also adds a check + which prevents the creation of layers with odd resolutions. + + Looking at cricket::GetSimulcastConfig for the version of webrtc.org in tree, + the number of simulcast layers is limited to one, or two if a field experiment + is enabled. That code also limits resolutions at which screensharing is allowed + as well as the number of layers that can be created for each resolution, and + ensures that each layer is exactly half the size of the layer above. + + Adding these new constraints to CreateEncoderStreams makes us more consistent + with what the webrtc.org code would do when creating streams, which should + help to avoid more assertion failures in the future. Long term, I believe we + should just switch to using cricket::GetSimulcastConfig. + + MozReview-Commit-ID: 8gjdY5GPPjl + + --HG-- + extra : source : 5c5a16ba81b7a2599d2764164d959a549a131d0a +--- + media/webrtc/signaling/src/media-conduit/VideoConduit.cpp | 15 ++++++++++++++- + 1 file changed, 14 insertions(+), 1 deletion(-) + +diff --git media/webrtc/signaling/src/media-conduit/VideoConduit.cpp media/webrtc/signaling/src/media-conduit/VideoConduit.cpp +index b67e1d475e50..aafcbd3d4ddc 100644 +--- media/webrtc/signaling/src/media-conduit/VideoConduit.cpp ++++ media/webrtc/signaling/src/media-conduit/VideoConduit.cpp +@@ -579,7 +579,20 @@ std::vector + WebrtcVideoConduit::VideoStreamFactory::CreateEncoderStreams(int width, int height, + const webrtc::VideoEncoderConfig& config) + { +- auto streamCount = config.number_of_streams; ++ size_t streamCount = config.number_of_streams; ++ ++ // Disallow odd width and height, they will cause aspect ratio checks to ++ // fail in the webrtc.org code. We can hit transient states after window ++ // sharing ends where odd resolutions are requested for the camera. ++ streamCount = std::min(streamCount, static_cast( ++ 1 + std::min(CountTrailingZeroes32(width), ++ CountTrailingZeroes32(height)))); ++ ++ // We only allow one layer when screensharing ++ if (mConduit->mCodecMode == webrtc::VideoCodecMode::kScreensharing) { ++ streamCount = 1; ++ } ++ + std::vector streams; + streams.reserve(streamCount); + MOZ_ASSERT(mConduit); + +commit 18e2cf9aac7a +Author: Dan Minor +Date: Wed Apr 4 09:24:28 2018 -0400 + + Bug 1432793 - Add mochitest for odd simulcast resolutions. r=bwc, a=RyanVM + + This creates a simulcast stream with an odd resolution. This previously would + have caused a runtime assertion failure and crash. + + MozReview-Commit-ID: IsywVOu6UeV + + --HG-- + extra : source : f1929e2b77a96af699e244f96bc4ecc17d34ece5 +--- + dom/media/tests/mochitest/head.js | 11 ++- + dom/media/tests/mochitest/mochitest.ini | 2 + + ...test_peerConnection_simulcastOddResolution.html | 91 ++++++++++++++++++++++ + 3 files changed, 100 insertions(+), 4 deletions(-) + +diff --git dom/media/tests/mochitest/head.js dom/media/tests/mochitest/head.js +index b125ecdeecf6..9bdfcdbfaf69 100644 +--- dom/media/tests/mochitest/head.js ++++ dom/media/tests/mochitest/head.js +@@ -994,11 +994,14 @@ AudioStreamHelper.prototype = { + } + + class VideoFrameEmitter { +- constructor(color1, color2, size) { +- if (!size) { +- size = 50; ++ constructor(color1, color2, width, height) { ++ if (!width) { ++ width = 50; + } +- this._helper = new CaptureStreamTestHelper2D(size, size); ++ if (!height) { ++ height = width; ++ } ++ this._helper = new CaptureStreamTestHelper2D(width, height); + this._canvas = this._helper.createAndAppendElement('canvas', 'source_canvas'); + this._color1 = color1 ? color1 : this._helper.green; + this._color2 = color2 ? color2 : this._helper.red; +diff --git dom/media/tests/mochitest/mochitest.ini dom/media/tests/mochitest/mochitest.ini +index 43e8492b9295..07c0876318a0 100644 +--- dom/media/tests/mochitest/mochitest.ini ++++ dom/media/tests/mochitest/mochitest.ini +@@ -194,6 +194,8 @@ skip-if = (android_version == '18') # android(Bug 1189784, timeouts on 4.3 emula + skip-if = android_version # no simulcast support on android + [test_peerConnection_simulcastAnswer.html] + skip-if = android_version # no simulcast support on android ++[test_peerConnection_simulcastOddResolution.html] ++skip-if = android_version # no simulcast support on android + #[test_peerConnection_relayOnly.html] + [test_peerConnection_callbacks.html] + skip-if = toolkit == 'android' # android(Bug 1189784, timeouts on 4.3 emulator) +diff --git dom/media/tests/mochitest/test_peerConnection_simulcastOddResolution.html dom/media/tests/mochitest/test_peerConnection_simulcastOddResolution.html +new file mode 100644 +index 000000000000..351582b69fab +--- /dev/null ++++ dom/media/tests/mochitest/test_peerConnection_simulcastOddResolution.html +@@ -0,0 +1,91 @@ ++ ++ ++ ++ ++ ++ ++ ++
++
++
++ ++ Property changes on: branches/2018Q2/www/waterfox/files/patch-bug1432793 ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: branches/2018Q2 =================================================================== --- branches/2018Q2 (revision 466931) +++ branches/2018Q2 (revision 466932) Property changes on: branches/2018Q2 ___________________________________________________________________ Modified: svn:mergeinfo ## -0,0 +0,1 ## Merged /head:r466918