diff --git a/MozillaFirefox.changes b/MozillaFirefox.changes index d3e70ea..d6be01a 100644 --- a/MozillaFirefox.changes +++ b/MozillaFirefox.changes @@ -1,3 +1,24 @@ +------------------------------------------------------------------- +Sat Jun 2 08:22:51 UTC 2012 - wr@rosenauer.org + +- update to Firefox 13.0 (bnc#765204) + * MFSA 2012-34/CVE-2012-1938/CVE-2012-1937/CVE-2011-3101 + Miscellaneous memory safety hazards + * MFSA 2012-36/CVE-2012-1944 (bmo#751422) + Content Security Policy inline-script bypass + * MFSA 2012-37/CVE-2012-1945 (bmo#670514) + Information disclosure though Windows file shares and shortcut + files + * MFSA 2012-38/CVE-2012-1946 (bmo#750109) + Use-after-free while replacing/inserting a node in a document + * MFSA 2012-40/CVE-2012-1947/CVE-2012-1940/CVE-2012-1941 + Buffer overflow and use-after-free issues found using Address + Sanitizer +- require NSS 3.13.4 + * MFSA 2012-39/CVE-2012-0441 (bmo#715073) +- fix sound notifications when filename/path contains a whitespace + (bmo#749739) + ------------------------------------------------------------------- Wed May 23 14:40:16 UTC 2012 - adrian@suse.de diff --git a/MozillaFirefox.spec b/MozillaFirefox.spec index ea861ce..c1f8964 100644 --- a/MozillaFirefox.spec +++ b/MozillaFirefox.spec @@ -17,7 +17,7 @@ # -%define major 12 +%define major 13 %define mainver %major.0 %define update_channel release @@ -45,11 +45,11 @@ BuildRequires: libproxy-devel BuildRequires: wireless-tools %endif BuildRequires: mozilla-nspr-devel >= 4.9.0 -BuildRequires: mozilla-nss-devel >= 3.13.3 +BuildRequires: mozilla-nss-devel >= 3.13.4 BuildRequires: nss-shared-helper-devel Version: %{mainver} Release: 0 -%define releasedate 2012042100 +%define releasedate 2012060100 Provides: firefox = %{mainver} Provides: firefox = %{version}-%{release} Provides: web_browser @@ -91,10 +91,12 @@ Patch11: mozilla-sle11.patch Patch12: mozilla-linux3.patch Patch14: mozilla-disable-neon-option.patch Patch15: mozilla-yarr-pcre.patch -Patch16: mozilla-revert_621446.patch -Patch17: mozilla-libnotify.patch -Patch18: mozilla-gcc47.patch -Patch19: mozilla-arm-disable-edsp.patch +Patch16: mozilla-system-nspr.patch +Patch17: mozilla-revert_621446.patch +Patch18: mozilla-libnotify.patch +Patch19: mozilla-gcc47.patch +Patch20: mozilla-nsSound.patch +Patch21: mozilla-arm-disable-edsp.patch # Firefox/browser Patch31: firefox-browser-css.patch Patch32: firefox-cross-desktop.patch @@ -131,6 +133,10 @@ Recommends: libcanberra0 %else %define crashreporter 1 %endif +# temporary gcc 4.7 +%if %suse_version > 1210 +%define crashreporter 0 +%endif ### build options end %description @@ -165,7 +171,7 @@ of MozillaFirefox. %package translations-other Summary: Extra translations for MozillaFirefox Group: System/Localization -Provides: locale(%{name}:af;ak;as;ast;be;bg;bn_BD;bn_IN;br;bs;csb;cy;el;en_ZA;eo;es_MX;et;eu;fa;fy_NL;ga_IE;gd;gl;gu_IN;he;hi_IN;hr;hy_AM;id;is;kk;km;kn;ku;lg;lij;lt;lv;mai;mk;ml;mn;mr;nn_NO;nso;or;pa_IN;rm;ro;si;sk;sl;son;sq;sr;sw;ta;ta_LK;te;th;tr;uk;vi;zu) +Provides: locale(%{name}:af;ak;as;ast;be;bg;bn_BD;bn_IN;br;bs;csb;cy;el;en_ZA;eo;es_MX;et;eu;fa;fy_NL;ga_IE;gd;gl;gu_IN;he;hi_IN;hr;hy_AM;id;is;kk;km;kn;ku;lg;lij;lt;lv;mai;mk;ml;mr;nn_NO;nso;or;pa_IN;rm;ro;si;sk;sl;son;sq;sr;ta;ta_LK;te;th;tr;uk;vi;zu) Requires: %{name} = %{version} Obsoletes: %{name}-translations < %{version}-%{release} @@ -228,6 +234,8 @@ cd $RPM_BUILD_DIR/mozilla %patch17 -p1 %patch18 -p1 %patch19 -p1 +%patch20 -p1 +%patch21 -p1 # %patch31 -p1 %patch32 -p1 @@ -539,6 +547,7 @@ exit 0 %{progdir}/distribution/extensions/ %{progdir}/extensions/{972ce4c6-7e08-4474-a285-3208198ce6fd} %{progdir}/icons/ +%{progdir}/jssubloader/ %{progdir}/searchplugins/ %attr(755,root,root) %{progdir}/%{progname}.sh %{progdir}/firefox-bin diff --git a/compare-locales.tar.bz2 b/compare-locales.tar.bz2 index 2a46cdd..0ab721d 100644 --- a/compare-locales.tar.bz2 +++ b/compare-locales.tar.bz2 @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bd133c57e1e6c71dda3d593853125ab27073ab32bafd568fe441baff47c3a32d -size 29339 +oid sha256:7793798b58360f3b866a9471267acb99a4ca43578f833088e0bb1843910512f4 +size 29324 diff --git a/create-tar.sh b/create-tar.sh index c89460a..e020875 100644 --- a/create-tar.sh +++ b/create-tar.sh @@ -2,8 +2,8 @@ CHANNEL="release" BRANCH="releases/mozilla-$CHANNEL" -RELEASE_TAG="FIREFOX_12_0_RELEASE" -VERSION="12.0" +RELEASE_TAG="FIREFOX_13_0_RELEASE" +VERSION="13.0" # mozilla echo "cloning $BRANCH..." diff --git a/firefox-12.0-source.tar.bz2 b/firefox-12.0-source.tar.bz2 deleted file mode 100644 index c0e1472..0000000 --- a/firefox-12.0-source.tar.bz2 +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:9b78faebdac7c27c203f50965280b5b0332f3cc72b37106d201eaa09516b98ef -size 78962014 diff --git a/firefox-13.0-source.tar.bz2 b/firefox-13.0-source.tar.bz2 new file mode 100644 index 0000000..970745d --- /dev/null +++ b/firefox-13.0-source.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:59e7118241c38958f151df4dfc98762840eece06389406e884583ec735da7dfa +size 79540331 diff --git a/firefox-branded-icons.patch b/firefox-branded-icons.patch index f8576da..bf71014 100644 --- a/firefox-branded-icons.patch +++ b/firefox-branded-icons.patch @@ -1,11 +1,11 @@ # HG changeset patch -# Parent d6bb5c163142d233d00e739e21aa9df16077873e +# Parent 4a29f791f190ebb5de41590d70d52c7510d9477c diff --git a/browser/app/Makefile.in b/browser/app/Makefile.in --- a/browser/app/Makefile.in +++ b/browser/app/Makefile.in -@@ -164,16 +164,21 @@ endif # LIBXUL_SDK - DEFINES += -DFIREFOX_ICO=\"$(DIST)/branding/firefox.ico\" -DDOCUMENT_ICO=\"$(DIST)/branding/document.ico\" +@@ -160,16 +160,21 @@ endif + endif # LIBXUL_SDK ifeq ($(MOZ_WIDGET_TOOLKIT),gtk2) libs:: @@ -54,7 +54,7 @@ diff --git a/browser/branding/official/Makefile.in b/browser/branding/official/M diff --git a/browser/installer/package-manifest.in b/browser/installer/package-manifest.in --- a/browser/installer/package-manifest.in +++ b/browser/installer/package-manifest.in -@@ -432,18 +432,21 @@ +@@ -450,18 +450,21 @@ @BINPATH@/extensions/{972ce4c6-7e08-4474-a285-3208198ce6fd}/preview.png #ifdef SHIP_FEEDBACK @BINPATH@/distribution/extensions/testpilot@labs.mozilla.com.xpi diff --git a/firefox-cross-desktop.patch b/firefox-cross-desktop.patch index b507f91..816dd72 100644 --- a/firefox-cross-desktop.patch +++ b/firefox-cross-desktop.patch @@ -1,14 +1,12 @@ -From: Wolfgang Rosenauer -NonGnome/KDE integration - -References: -https://bugzilla.novell.com/show_bug.cgi?id=170055 +# HG changeset patch +# Parent fd2da289a3c15b8c96c248df2710d879793f22c9 +# User Wolfgang Rosenauer +Bug 526717 - remove non-working "Set as desktop background" from the UI for unsupported desktops diff --git a/browser/base/content/nsContextMenu.js b/browser/base/content/nsContextMenu.js --- a/browser/base/content/nsContextMenu.js +++ b/browser/base/content/nsContextMenu.js -@@ -237,17 +237,19 @@ nsContextMenu.prototype = { - this.showItem("context-sep-viewsource", shouldShow); +@@ -262,17 +262,17 @@ nsContextMenu.prototype = { // Set as Desktop background depends on whether an image was clicked on, // and only works if we have a shell service. @@ -16,11 +14,9 @@ diff --git a/browser/base/content/nsContextMenu.js b/browser/base/content/nsCont #ifdef HAVE_SHELL_SERVICE // Only enable Set as Desktop Background if we can get the shell service. var shell = getShellService(); -- if (shell) -+ var env = Components.classes["@mozilla.org/process/environment;1"] -+ .getService(Components.interfaces.nsIEnvironment); -+ if (shell && env.get('DESKTOP_SESSION') == "gnome") - haveSetDesktopBackground = true; + if (shell) +- haveSetDesktopBackground = true; ++ haveSetDesktopBackground = shell.canSetDesktopBackground; #endif this.showItem("context-setDesktopBackground", haveSetDesktopBackground && this.onLoadedImage); @@ -28,3 +24,68 @@ diff --git a/browser/base/content/nsContextMenu.js b/browser/base/content/nsCont if (haveSetDesktopBackground && this.onLoadedImage) { document.getElementById("context-setDesktopBackground") .disabled = this.disableSetDesktopBackground(); + } +diff --git a/browser/components/shell/public/nsIShellService.idl b/browser/components/shell/public/nsIShellService.idl +--- a/browser/components/shell/public/nsIShellService.idl ++++ b/browser/components/shell/public/nsIShellService.idl +@@ -69,16 +69,25 @@ interface nsIShellService : nsISupports + /** + * Used to determine whether or not to show a "Set Default Browser" + * query dialog. This attribute is true if the application is starting + * up and "browser.shell.checkDefaultBrowser" is true, otherwise it + * is false. + */ + attribute boolean shouldCheckDefaultBrowser; + ++ /** ++ * Used to determine whether or not to offer "Set as desktop background" ++ * context menu item. Even if shell service is available it is not ++ * guaranteed that it is able to set the background for every desktop ++ * which is especially true for Linux with its many different desktop ++ * environments. ++ */ ++ readonly attribute boolean canSetDesktopBackground; ++ + /** + * Flags for positioning/sizing of the Desktop Background image. + */ + const long BACKGROUND_TILE = 1; + const long BACKGROUND_STRETCH = 2; + const long BACKGROUND_CENTER = 3; + const long BACKGROUND_FILL = 4; + const long BACKGROUND_FIT = 5; +diff --git a/browser/components/shell/src/nsGNOMEShellService.cpp b/browser/components/shell/src/nsGNOMEShellService.cpp +--- a/browser/components/shell/src/nsGNOMEShellService.cpp ++++ b/browser/components/shell/src/nsGNOMEShellService.cpp +@@ -377,16 +377,31 @@ nsGNOMEShellService::SetShouldCheckDefau + pserve->GetBranch("", getter_AddRefs(prefs)); + + if (prefs) + prefs->SetBoolPref(PREF_CHECKDEFAULTBROWSER, aShouldCheck); + + return NS_OK; + } + ++NS_IMETHODIMP ++nsGNOMEShellService::GetCanSetDesktopBackground(bool* aResult) ++{ ++ // setting desktop background is currently only supported ++ // for Gnome or desktops using the same GSettings and GConf keys ++ const char* gnomeSession = getenv("GNOME_DESKTOP_SESSION_ID"); ++ if (gnomeSession) { ++ *aResult = true; ++ } else { ++ *aResult = false; ++ } ++ ++ return NS_OK; ++} ++ + static nsresult + WriteImage(const nsCString& aPath, imgIContainer* aImage) + { + #ifndef MOZ_WIDGET_GTK2 + return NS_ERROR_NOT_AVAILABLE; + #else + nsCOMPtr imgToPixbuf = + do_GetService("@mozilla.org/widget/image-to-gdk-pixbuf;1"); diff --git a/firefox-kde.patch b/firefox-kde.patch index 9d5ad06..892a0b3 100644 --- a/firefox-kde.patch +++ b/firefox-kde.patch @@ -2,7 +2,7 @@ diff --git a/browser/base/content/browser-kde.xul b/browser/base/content/browser new file mode 100644 --- /dev/null +++ b/browser/base/content/browser-kde.xul -@@ -0,0 +1,1118 @@ +@@ -0,0 +1,1116 @@ +#filter substitution + +# -*- Mode: HTML -*- @@ -43,6 +43,7 @@ new file mode 100644 +# David Dahl +# Frank Yan +# Victor Porof ++# Paul Rouget +# +# Alternatively, the contents of this file may be used under the terms of +# either the GNU General Public License Version 2 or later (the "GPL"), or @@ -95,6 +96,7 @@ new file mode 100644 + lightweightthemes="true" + lightweightthemesfooter="browser-bottombox" + windowtype="navigator:browser" ++ macanimationtype="document" + screenX="4" screenY="4" + browsingmode="normal" + persist="screenX screenY width height sizemode"> @@ -231,20 +233,21 @@ new file mode 100644 + + + -+ ++ ++ ++ ++ ++ ++ + + @@ -309,7 +312,7 @@ new file mode 100644 + type="arrow" + hidden="true" + noautofocus="true" -+ onpopupshown="document.getElementById('identity-popup-more-info-button').focus();" ++ onpopupshown="gIdentityHandler.onPopupShown(event);" + level="top"> + + @@ -476,7 +479,7 @@ new file mode 100644 + toolbarname="&navbarCmd.label;" accesskey="&navbarCmd.accesskey;" + fullscreentoolbar="true" mode="icons" customizable="true" + iconsize="large" -+ defaultset="unified-back-forward-button,urlbar-container,reload-button,stop-button,search-container,home-button,bookmarks-menu-button-container,fullscreenflex,window-controls" ++ defaultset="unified-back-forward-button,urlbar-container,reload-button,stop-button,search-container,home-button,bookmarks-menu-button-container,window-controls" + context="toolbar-context-menu"> + + + + ++ + + -+ ++ ++ ++ ++ ++ +#ifndef XP_MACOSX -+ ++ +#endif -+ -+ + + + + -+ -+ -+ -+ -+ ++ + + + @@ -1124,10 +1122,10 @@ new file mode 100644 diff --git a/browser/base/jar.mn b/browser/base/jar.mn --- a/browser/base/jar.mn +++ b/browser/base/jar.mn -@@ -23,16 +23,18 @@ browser.jar: - content/browser/aboutHome-restore-icon-small.png (content/aboutHome-restore-icon-small.png) - content/browser/aboutHome-snippet1.png (content/aboutHome-snippet1.png) - content/browser/aboutHome-snippet2.png (content/aboutHome-snippet2.png) +@@ -32,16 +32,18 @@ browser.jar: + content/browser/abouthome/restore-large.png (content/abouthome/restore-large.png) + content/browser/abouthome/mozilla.png (content/abouthome/mozilla.png) + content/browser/abouthome/noise.png (content/abouthome/noise.png) content/browser/aboutRobots-icon.png (content/aboutRobots-icon.png) content/browser/aboutRobots-widget-left.png (content/aboutRobots-widget-left.png) * content/browser/browser.css (content/browser.css) @@ -1137,12 +1135,12 @@ diff --git a/browser/base/jar.mn b/browser/base/jar.mn +% override chrome://browser/content/browser.xul chrome://browser/content/browser-kde.xul desktop=kde * content/browser/browser-tabPreviews.xml (content/browser-tabPreviews.xml) * content/browser/content.js (content/content.js) - * content/browser/fullscreen-video.xhtml (content/fullscreen-video.xhtml) * content/browser/newtab/newTab.xul (content/newtab/newTab.xul) * content/browser/newtab/newTab.js (content/newtab/newTab.js) content/browser/newtab/newTab.css (content/newtab/newTab.css) * content/browser/pageinfo/pageInfo.xul (content/pageinfo/pageInfo.xul) * content/browser/pageinfo/pageInfo.js (content/pageinfo/pageInfo.js) + * content/browser/pageinfo/pageInfo.css (content/pageinfo/pageInfo.css) diff --git a/browser/components/build/nsModule.cpp b/browser/components/build/nsModule.cpp --- a/browser/components/build/nsModule.cpp +++ b/browser/components/build/nsModule.cpp @@ -1277,7 +1275,7 @@ diff --git a/browser/components/shell/src/nsKDEShellService.cpp b/browser/compon new file mode 100644 --- /dev/null +++ b/browser/components/shell/src/nsKDEShellService.cpp -@@ -0,0 +1,257 @@ +@@ -0,0 +1,264 @@ +/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* ***** BEGIN LICENSE BLOCK ***** + * Version: MPL 1.1/GPL 2.0/LGPL 2.1 @@ -1419,6 +1417,13 @@ new file mode 100644 +} + +NS_IMETHODIMP ++nsKDEShellService::GetCanSetDesktopBackground(bool* aResult) ++{ ++ *aResult = true; ++ return NS_OK; ++} ++ ++NS_IMETHODIMP +nsKDEShellService::SetDesktopBackground(nsIDOMElement* aElement, + PRInt32 aPosition) + { @@ -1709,7 +1714,7 @@ new file mode 100644 diff --git a/browser/installer/package-manifest.in b/browser/installer/package-manifest.in --- a/browser/installer/package-manifest.in +++ b/browser/installer/package-manifest.in -@@ -450,16 +450,17 @@ +@@ -467,16 +467,17 @@ #endif #endif diff --git a/firefox-no-default-ualocale.patch b/firefox-no-default-ualocale.patch index 03108a3..684d6e8 100644 --- a/firefox-no-default-ualocale.patch +++ b/firefox-no-default-ualocale.patch @@ -1,12 +1,12 @@ # HG changeset patch # User Wolfgang Rosenauer -# Parent d372da4f99f10c6e76fd483abc145cfbc485c168 +# Parent be9f4eae7dc69ed989cc9f9259b3bb73d1f5dbf9 Do not overwrite the locale dynamic pref from xulrunner's all.js with a wrong default value diff --git a/browser/app/profile/firefox.js b/browser/app/profile/firefox.js --- a/browser/app/profile/firefox.js +++ b/browser/app/profile/firefox.js -@@ -230,17 +230,17 @@ pref("xpinstall.whitelist.add.36", "getp +@@ -231,17 +231,17 @@ pref("xpinstall.whitelist.add.36", "getp pref("lightweightThemes.update.enabled", true); @@ -19,7 +19,7 @@ diff --git a/browser/app/profile/firefox.js b/browser/app/profile/firefox.js +pref("general.useragent.locale", "chrome://global/locale/intl.properties"); pref("general.skins.selectedSkin", "classic/1.0"); - pref("general.smoothScroll", false); + pref("general.smoothScroll", true); #ifdef UNIX_BUT_NOT_MAC pref("general.autoScroll", false); #else diff --git a/l10n-12.0.tar.bz2 b/l10n-12.0.tar.bz2 deleted file mode 100644 index ce54abf..0000000 --- a/l10n-12.0.tar.bz2 +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:0d2f7bce994d733d280deed22abbc7c5531a215ba8c7025611fc13ebf036bda6 -size 47298192 diff --git a/l10n-13.0.tar.bz2 b/l10n-13.0.tar.bz2 new file mode 100644 index 0000000..55ae712 --- /dev/null +++ b/l10n-13.0.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4aaf6de4c404550f2f4a9d19556f294210f9e8eb91c502a918cd4a3ec9325c33 +size 48694368 diff --git a/mozilla-gcc47.patch b/mozilla-gcc47.patch index 9625503..2f00638 100644 --- a/mozilla-gcc47.patch +++ b/mozilla-gcc47.patch @@ -1,78 +1,9 @@ # HG changeset patch -# Parent 93e5d3b8061741abc83dcd4ed0fe93f1636583ef +# Parent 7bc8f0e5bed8cb2212e27228e628861737256459 Patch to make Mozilla build with gcc 4.7, including -- Bug 725655 - gcc 4.7 build failures (missing headers) (TM: Mozilla13) - Bug 734490 - "no viable overloaded 'PRIxPTR'" when building with Clang or GCC 4.7 (TM: Mozilla14) - Bug 741348 - Work around crashreporter client build failure with gcc 4.7 (TM: Mozilla15) -diff --git a/ipc/chromium/src/base/file_util_linux.cc b/ipc/chromium/src/base/file_util_linux.cc ---- a/ipc/chromium/src/base/file_util_linux.cc -+++ b/ipc/chromium/src/base/file_util_linux.cc -@@ -1,15 +1,18 @@ - // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. - // Use of this source code is governed by a BSD-style license that can be - // found in the LICENSE file. - - #include "base/file_util.h" - - #include -+#if defined(ANDROID) || defined(OS_POSIX) -+#include -+#endif - - #include - #include - - #include "base/eintr_wrapper.h" - #include "base/file_path.h" - #include "base/string_util.h" - -diff --git a/ipc/chromium/src/base/message_pump_libevent.cc b/ipc/chromium/src/base/message_pump_libevent.cc ---- a/ipc/chromium/src/base/message_pump_libevent.cc -+++ b/ipc/chromium/src/base/message_pump_libevent.cc -@@ -1,16 +1,19 @@ - // Copyright (c) 2008 The Chromium Authors. All rights reserved. - // Use of this source code is governed by a BSD-style license that can be - // found in the LICENSE file. - - #include "base/message_pump_libevent.h" - - #include - #include -+#if defined(ANDROID) || defined(OS_POSIX) -+#include -+#endif - - #include "eintr_wrapper.h" - #include "base/logging.h" - #include "base/scoped_nsautorelease_pool.h" - #include "base/scoped_ptr.h" - #include "base/time.h" - #include "third_party/libevent/event.h" - -diff --git a/ipc/chromium/src/base/time_posix.cc b/ipc/chromium/src/base/time_posix.cc ---- a/ipc/chromium/src/base/time_posix.cc -+++ b/ipc/chromium/src/base/time_posix.cc -@@ -8,16 +8,19 @@ - #include - #endif - #include - #ifdef ANDROID - #include - #else - #include - #endif -+#if defined(ANDROID) || defined(OS_POSIX) -+#include -+#endif - - #include - - #include "base/basictypes.h" - #include "base/logging.h" - - namespace base { - diff --git a/layout/base/tests/TestPoisonArea.cpp b/layout/base/tests/TestPoisonArea.cpp --- a/layout/base/tests/TestPoisonArea.cpp +++ b/layout/base/tests/TestPoisonArea.cpp diff --git a/mozilla-kde.patch b/mozilla-kde.patch index b3008ee..ec5bd5c 100644 --- a/mozilla-kde.patch +++ b/mozilla-kde.patch @@ -27,7 +27,7 @@ diff --git a/modules/libpref/src/Makefile.in b/modules/libpref/src/Makefile.in diff --git a/modules/libpref/src/Preferences.cpp b/modules/libpref/src/Preferences.cpp --- a/modules/libpref/src/Preferences.cpp +++ b/modules/libpref/src/Preferences.cpp -@@ -56,16 +56,17 @@ +@@ -57,16 +57,17 @@ #include "nsIStringEnumerator.h" #include "nsIZipReader.h" #include "nsPrefBranch.h" @@ -45,14 +45,14 @@ diff --git a/modules/libpref/src/Preferences.cpp b/modules/libpref/src/Preferenc #include "prefapi.h" #include "prefread.h" #include "prefapi_private_data.h" -@@ -935,30 +936,48 @@ pref_LoadPrefsInDir(nsIFile* aDir, char - } +@@ -937,16 +938,34 @@ pref_LoadPrefsInDir(nsIFile* aDir, char static nsresult pref_LoadPrefsInDirList(const char *listId) { nsresult rv; nsCOMPtr dirSvc(do_GetService(NS_DIRECTORY_SERVICE_CONTRACTID, &rv)); - if (NS_FAILED(rv)) return rv; + if (NS_FAILED(rv)) + return rv; + // make sure we load these special files after all the others + static const char* specialFiles[] = { @@ -72,30 +72,34 @@ diff --git a/modules/libpref/src/Preferences.cpp b/modules/libpref/src/Preferenc + } + } + - nsCOMPtr dirList; + nsCOMPtr list; dirSvc->Get(listId, NS_GET_IID(nsISimpleEnumerator), - getter_AddRefs(dirList)); - if (dirList) { - bool hasMore; - while (NS_SUCCEEDED(dirList->HasMoreElements(&hasMore)) && hasMore) { - nsCOMPtr elem; - dirList->GetNext(getter_AddRefs(elem)); - if (elem) { - nsCOMPtr dir = do_QueryInterface(elem); - if (dir) { - // Do we care if a file provided by this process fails to load? -- pref_LoadPrefsInDir(dir, nsnull, 0); -+ pref_LoadPrefsInDir(dir, specialFiles, NS_ARRAY_LENGTH(specialFiles)); - } - } - } + getter_AddRefs(list)); + if (!list) + return NS_OK; + + bool hasMore; +@@ -962,17 +981,17 @@ static nsresult pref_LoadPrefsInDirList( + + nsCAutoString leaf; + path->GetNativeLeafName(leaf); + + // Do we care if a file provided by this process fails to load? + if (Substring(leaf, leaf.Length() - 4).Equals(NS_LITERAL_CSTRING(".xpi"))) + ReadExtensionPrefs(path); + else +- pref_LoadPrefsInDir(path, nsnull, 0); ++ pref_LoadPrefsInDir(path, specialFiles, NS_ARRAY_LENGTH(specialFiles)); } return NS_OK; } static nsresult pref_ReadPrefFromJar(nsZipArchive* jarReader, const char *name) -@@ -1051,28 +1070,40 @@ static nsresult pref_InitInitialObjects( + { + nsZipItemPtr manifest(jarReader, name, true); + NS_ENSURE_TRUE(manifest.Buffer(), NS_ERROR_NOT_AVAILABLE); +@@ -1062,28 +1081,40 @@ static nsresult pref_InitInitialObjects( /* these pref file names should not be used: we process them after all other application pref files for backwards compatibility */ static const char* specialFiles[] = { #if defined(XP_MACOSX) @@ -139,17 +143,18 @@ diff --git a/modules/libpref/src/Preferences.cpp b/modules/libpref/src/Preferenc diff --git a/toolkit/components/downloads/Makefile.in b/toolkit/components/downloads/Makefile.in --- a/toolkit/components/downloads/Makefile.in +++ b/toolkit/components/downloads/Makefile.in -@@ -75,8 +75,10 @@ EXTRA_COMPONENTS = \ +@@ -73,8 +73,11 @@ EXTRA_COMPONENTS = \ + nsDownloadManagerUI.js \ + nsDownloadManagerUI.manifest \ $(NULL) endif - ifdef ENABLE_TESTS - DIRS += test - endif + TEST_DIRS += test include $(topsrcdir)/config/rules.mk + +LOCAL_INCLUDES += -I$(topsrcdir)/toolkit/xre ++ diff --git a/toolkit/components/downloads/nsDownloadManager.cpp b/toolkit/components/downloads/nsDownloadManager.cpp --- a/toolkit/components/downloads/nsDownloadManager.cpp +++ b/toolkit/components/downloads/nsDownloadManager.cpp @@ -174,7 +179,7 @@ diff --git a/toolkit/components/downloads/nsDownloadManager.cpp b/toolkit/compon #include "AndroidBridge.h" #endif -@@ -2214,16 +2218,25 @@ nsDownload::SetState(DownloadState aStat +@@ -2221,16 +2225,25 @@ nsDownload::SetState(DownloadState aStat nsCOMPtr pref(do_GetService(NS_PREFSERVICE_CONTRACTID)); // Master pref to control this function. @@ -200,7 +205,7 @@ diff --git a/toolkit/components/downloads/nsDownloadManager.cpp b/toolkit/compon PRInt64 goat = PR_Now() - mStartTime; showTaskbarAlert = goat > alertIntervalUSec; -@@ -2247,19 +2260,20 @@ nsDownload::SetState(DownloadState aStat +@@ -2254,19 +2267,20 @@ nsDownload::SetState(DownloadState aStat // If downloads are automatically removed per the user's // retention policy, there's no reason to make the text clickable // because if it is, they'll click open the download manager and @@ -225,7 +230,7 @@ diff --git a/toolkit/components/downloads/nsDownloadManager.cpp b/toolkit/compon diff --git a/toolkit/content/jar.mn b/toolkit/content/jar.mn --- a/toolkit/content/jar.mn +++ b/toolkit/content/jar.mn -@@ -40,29 +40,33 @@ toolkit.jar: +@@ -44,29 +44,33 @@ toolkit.jar: *+ content/global/viewZoomOverlay.js (viewZoomOverlay.js) *+ content/global/bindings/autocomplete.xml (widgets/autocomplete.xml) *+ content/global/bindings/browser.xml (widgets/browser.xml) @@ -2092,8 +2097,7 @@ new file mode 100644 diff --git a/toolkit/system/unixproxy/nsUnixSystemProxySettings.cpp b/toolkit/system/unixproxy/nsUnixSystemProxySettings.cpp --- a/toolkit/system/unixproxy/nsUnixSystemProxySettings.cpp +++ b/toolkit/system/unixproxy/nsUnixSystemProxySettings.cpp -@@ -45,16 +45,18 @@ - #include "nsReadableUtils.h" +@@ -46,16 +46,18 @@ #include "nsArrayUtils.h" #include "prnetdb.h" #include "prenv.h" @@ -2101,6 +2105,7 @@ diff --git a/toolkit/system/unixproxy/nsUnixSystemProxySettings.cpp b/toolkit/sy #include "nsNetUtil.h" #include "nsISupportsPrimitives.h" #include "nsIGSettingsService.h" + #include "nsInterfaceHashtable.h" +#include "nsVoidArray.h" +#include "nsKDEUtils.h" @@ -2111,10 +2116,10 @@ diff --git a/toolkit/system/unixproxy/nsUnixSystemProxySettings.cpp b/toolkit/sy nsUnixSystemProxySettings() {} nsresult Init(); -@@ -64,16 +66,17 @@ private: - - nsCOMPtr mGConf; +@@ -67,16 +69,17 @@ private: nsCOMPtr mGSettings; + nsCOMPtr mProxySettings; + nsInterfaceHashtable mSchemeProxySettings; bool IsProxyMode(const char* aMode); nsresult SetProxyResultFromGConf(const char* aKeyBase, const char* aType, nsACString& aResult); nsresult GetProxyFromGConf(const nsACString& aScheme, const nsACString& aHost, PRInt32 aPort, nsACString& aResult); @@ -2129,7 +2134,7 @@ diff --git a/toolkit/system/unixproxy/nsUnixSystemProxySettings.cpp b/toolkit/sy nsUnixSystemProxySettings::Init() { // If this is a GNOME session, load gconf and try to use its preferences. -@@ -526,16 +529,19 @@ nsUnixSystemProxySettings::GetProxyForUR +@@ -529,16 +532,19 @@ nsUnixSystemProxySettings::GetProxyForUR nsCAutoString host; rv = aURI->GetHost(host); NS_ENSURE_SUCCESS(rv, rv); @@ -2141,7 +2146,7 @@ diff --git a/toolkit/system/unixproxy/nsUnixSystemProxySettings.cpp b/toolkit/sy + if( nsKDEUtils::kdeSupport()) + return GetProxyFromKDE(scheme, host, port, aResult); + - if (mGSettings) { + if (mProxySettings) { rv = GetProxyFromGSettings(scheme, host, port, aResult); if (rv == NS_OK) return rv; @@ -2149,7 +2154,7 @@ diff --git a/toolkit/system/unixproxy/nsUnixSystemProxySettings.cpp b/toolkit/sy if (mGConf) return GetProxyFromGConf(scheme, host, port, aResult); -@@ -561,8 +567,34 @@ static const mozilla::Module::ContractID +@@ -564,8 +570,34 @@ static const mozilla::Module::ContractID static const mozilla::Module kUnixProxyModule = { mozilla::Module::kVersion, @@ -2673,7 +2678,7 @@ new file mode 100644 diff --git a/uriloader/exthandler/Makefile.in b/uriloader/exthandler/Makefile.in --- a/uriloader/exthandler/Makefile.in +++ b/uriloader/exthandler/Makefile.in -@@ -92,18 +92,19 @@ LOCAL_INCLUDES = -I$(srcdir) +@@ -90,18 +90,19 @@ LOCAL_INCLUDES = -I$(srcdir) LOCAL_INCLUDES += -I$(topsrcdir)/dom/base \ -I$(topsrcdir)/dom/ipc \ -I$(topsrcdir)/content/base/src \ @@ -3250,7 +3255,7 @@ diff --git a/uriloader/exthandler/unix/nsOSHelperAppService.cpp b/uriloader/exth diff --git a/widget/gtk2/Makefile.in b/widget/gtk2/Makefile.in --- a/widget/gtk2/Makefile.in +++ b/widget/gtk2/Makefile.in -@@ -135,11 +135,14 @@ DEFINES += -DCAIRO_GFX +@@ -135,11 +135,14 @@ DEFINES += -DCAIRO_GFX -DMOZ_APP_NAME=' INCLUDES += \ -I$(srcdir)/../xpwidgets \ @@ -3604,7 +3609,7 @@ diff --git a/widget/gtk2/nsFilePicker.h b/widget/gtk2/nsFilePicker.h diff --git a/xpcom/components/Makefile.in b/xpcom/components/Makefile.in --- a/xpcom/components/Makefile.in +++ b/xpcom/components/Makefile.in -@@ -92,10 +92,11 @@ LOCAL_INCLUDES = \ +@@ -91,10 +91,11 @@ LOCAL_INCLUDES = \ # we don't want the shared lib, but we want to force the creation of a static lib. FORCE_STATIC_LIB = 1 @@ -3619,134 +3624,134 @@ diff --git a/xpcom/components/Makefile.in b/xpcom/components/Makefile.in diff --git a/xpcom/components/ManifestParser.cpp b/xpcom/components/ManifestParser.cpp --- a/xpcom/components/ManifestParser.cpp +++ b/xpcom/components/ManifestParser.cpp -@@ -62,16 +62,17 @@ - #include "nsTextFormatter.h" - #include "nsVersionComparator.h" - #include "nsXPCOMCIDInternal.h" - - #include "nsIConsoleService.h" - #include "nsIScriptError.h" - #include "nsIXULAppInfo.h" - #include "nsIXULRuntime.h" -+#include "nsKDEUtils.h" - - using namespace mozilla; - - struct ManifestDirective - { - const char* directive; - int argc; - -@@ -429,16 +430,17 @@ ParseManifest(NSLocationType type, FileL - NS_NAMED_LITERAL_STRING(kPlatform, "platform"); - NS_NAMED_LITERAL_STRING(kContentAccessible, "contentaccessible"); - NS_NAMED_LITERAL_STRING(kApplication, "application"); - NS_NAMED_LITERAL_STRING(kAppVersion, "appversion"); - NS_NAMED_LITERAL_STRING(kGeckoVersion, "platformversion"); - NS_NAMED_LITERAL_STRING(kOs, "os"); - NS_NAMED_LITERAL_STRING(kOsVersion, "osversion"); - NS_NAMED_LITERAL_STRING(kABI, "abi"); -+ NS_NAMED_LITERAL_STRING(kDesktop, "desktop"); - #if defined(MOZ_WIDGET_ANDROID) - NS_NAMED_LITERAL_STRING(kTablet, "tablet"); - #endif - - // Obsolete - NS_NAMED_LITERAL_STRING(kXPCNativeWrappers, "xpcnativewrappers"); - - nsAutoString appID; -@@ -476,41 +478,46 @@ ParseManifest(NSLocationType type, FileL - CopyUTF8toUTF16(s, abi); - abi.Insert(PRUnichar('_'), 0); - abi.Insert(osTarget, 0); - } - } - } - - nsAutoString osVersion; -+ nsAutoString desktop; - #if defined(XP_WIN) - OSVERSIONINFO info = { sizeof(OSVERSIONINFO) }; - if (GetVersionEx(&info)) { - nsTextFormatter::ssprintf(osVersion, NS_LITERAL_STRING("%ld.%ld").get(), - info.dwMajorVersion, - info.dwMinorVersion); - } -+ desktop = NS_LITERAL_STRING("win"); - #elif defined(MOZ_WIDGET_COCOA) - SInt32 majorVersion, minorVersion; - if ((Gestalt(gestaltSystemVersionMajor, &majorVersion) == noErr) && - (Gestalt(gestaltSystemVersionMinor, &minorVersion) == noErr)) { - nsTextFormatter::ssprintf(osVersion, NS_LITERAL_STRING("%ld.%ld").get(), - majorVersion, - minorVersion); - } -+ desktop = NS_LITERAL_STRING("macosx"); - #elif defined(MOZ_WIDGET_GTK2) - nsTextFormatter::ssprintf(osVersion, NS_LITERAL_STRING("%ld.%ld").get(), - gtk_major_version, - gtk_minor_version); -+ desktop = nsKDEUtils::kdeSession() ? NS_LITERAL_STRING("kde") : NS_LITERAL_STRING("gnome"); - #elif defined(MOZ_WIDGET_ANDROID) - bool isTablet = false; - if (mozilla::AndroidBridge::Bridge()) { - mozilla::AndroidBridge::Bridge()->GetStaticStringField("android/os/Build$VERSION", "RELEASE", osVersion); - isTablet = mozilla::AndroidBridge::Bridge()->IsTablet(); - } -+ desktop = NS_LITERAL_STRING("android"); - #endif - - // Because contracts must be registered after CIDs, we save and process them - // at the end. - nsTArray contracts; - - char *token; - char *newline = buf; -@@ -592,24 +599,26 @@ ParseManifest(NSLocationType type, FileL - TriState stOsVersion = eUnspecified; - TriState stOs = eUnspecified; - TriState stABI = eUnspecified; - #if defined(MOZ_WIDGET_ANDROID) - TriState stTablet = eUnspecified; - #endif - bool platform = false; - bool contentAccessible = false; -+ TriState stDesktop = eUnspecified; - - while (NULL != (token = nsCRT::strtok(whitespace, kWhitespace, &whitespace)) && ok) { - ToLowerCase(token); - NS_ConvertASCIItoUTF16 wtoken(token); - - if (CheckStringFlag(kApplication, wtoken, appID, stApp) || - CheckStringFlag(kOs, wtoken, osTarget, stOs) || - CheckStringFlag(kABI, wtoken, abi, stABI) || -+ CheckStringFlag(kDesktop, wtoken, desktop, stDesktop) || - CheckVersionFlag(kOsVersion, wtoken, osVersion, stOsVersion) || - CheckVersionFlag(kAppVersion, wtoken, appVersion, stAppVersion) || - CheckVersionFlag(kGeckoVersion, wtoken, geckoVersion, stGeckoVersion)) - continue; - - #if defined(MOZ_WIDGET_ANDROID) - bool tablet = false; - if (CheckFlag(kTablet, wtoken, tablet)) { -@@ -638,16 +647,17 @@ ParseManifest(NSLocationType type, FileL - } - - if (!ok || - stApp == eBad || - stAppVersion == eBad || - stGeckoVersion == eBad || - stOs == eBad || - stOsVersion == eBad || -+ stDesktop == eBad || - #ifdef MOZ_WIDGET_ANDROID - stTablet == eBad || - #endif - stABI == eBad) - continue; - - if (directive->regfunc) { - if (GeckoProcessType_Default != XRE_GetProcessType()) +@@ -63,16 +63,17 @@ + #include "nsTextFormatter.h" + #include "nsVersionComparator.h" + #include "nsXPCOMCIDInternal.h" + + #include "nsIConsoleService.h" + #include "nsIScriptError.h" + #include "nsIXULAppInfo.h" + #include "nsIXULRuntime.h" ++#include "nsKDEUtils.h" + + using namespace mozilla; + + struct ManifestDirective + { + const char* directive; + int argc; + +@@ -430,16 +431,17 @@ ParseManifest(NSLocationType type, FileL + NS_NAMED_LITERAL_STRING(kPlatform, "platform"); + NS_NAMED_LITERAL_STRING(kContentAccessible, "contentaccessible"); + NS_NAMED_LITERAL_STRING(kApplication, "application"); + NS_NAMED_LITERAL_STRING(kAppVersion, "appversion"); + NS_NAMED_LITERAL_STRING(kGeckoVersion, "platformversion"); + NS_NAMED_LITERAL_STRING(kOs, "os"); + NS_NAMED_LITERAL_STRING(kOsVersion, "osversion"); + NS_NAMED_LITERAL_STRING(kABI, "abi"); ++ NS_NAMED_LITERAL_STRING(kDesktop, "desktop"); + #if defined(MOZ_WIDGET_ANDROID) + NS_NAMED_LITERAL_STRING(kTablet, "tablet"); + #endif + + // Obsolete + NS_NAMED_LITERAL_STRING(kXPCNativeWrappers, "xpcnativewrappers"); + + nsAutoString appID; +@@ -477,41 +479,46 @@ ParseManifest(NSLocationType type, FileL + CopyUTF8toUTF16(s, abi); + abi.Insert(PRUnichar('_'), 0); + abi.Insert(osTarget, 0); + } + } + } + + nsAutoString osVersion; ++ nsAutoString desktop; + #if defined(XP_WIN) + OSVERSIONINFO info = { sizeof(OSVERSIONINFO) }; + if (GetVersionEx(&info)) { + nsTextFormatter::ssprintf(osVersion, NS_LITERAL_STRING("%ld.%ld").get(), + info.dwMajorVersion, + info.dwMinorVersion); + } ++ desktop = NS_LITERAL_STRING("win"); + #elif defined(MOZ_WIDGET_COCOA) + SInt32 majorVersion, minorVersion; + if ((Gestalt(gestaltSystemVersionMajor, &majorVersion) == noErr) && + (Gestalt(gestaltSystemVersionMinor, &minorVersion) == noErr)) { + nsTextFormatter::ssprintf(osVersion, NS_LITERAL_STRING("%ld.%ld").get(), + majorVersion, + minorVersion); + } ++ desktop = NS_LITERAL_STRING("macosx"); + #elif defined(MOZ_WIDGET_GTK2) + nsTextFormatter::ssprintf(osVersion, NS_LITERAL_STRING("%ld.%ld").get(), + gtk_major_version, + gtk_minor_version); ++ desktop = nsKDEUtils::kdeSession() ? NS_LITERAL_STRING("kde") : NS_LITERAL_STRING("gnome"); + #elif defined(MOZ_WIDGET_ANDROID) + bool isTablet = false; + if (mozilla::AndroidBridge::Bridge()) { + mozilla::AndroidBridge::Bridge()->GetStaticStringField("android/os/Build$VERSION", "RELEASE", osVersion); + isTablet = mozilla::AndroidBridge::Bridge()->IsTablet(); + } ++ desktop = NS_LITERAL_STRING("android"); + #endif + + // Because contracts must be registered after CIDs, we save and process them + // at the end. + nsTArray contracts; + + char *token; + char *newline = buf; +@@ -593,24 +600,26 @@ ParseManifest(NSLocationType type, FileL + TriState stOsVersion = eUnspecified; + TriState stOs = eUnspecified; + TriState stABI = eUnspecified; + #if defined(MOZ_WIDGET_ANDROID) + TriState stTablet = eUnspecified; + #endif + bool platform = false; + bool contentAccessible = false; ++ TriState stDesktop = eUnspecified; + + while (NULL != (token = nsCRT::strtok(whitespace, kWhitespace, &whitespace)) && ok) { + ToLowerCase(token); + NS_ConvertASCIItoUTF16 wtoken(token); + + if (CheckStringFlag(kApplication, wtoken, appID, stApp) || + CheckStringFlag(kOs, wtoken, osTarget, stOs) || + CheckStringFlag(kABI, wtoken, abi, stABI) || ++ CheckStringFlag(kDesktop, wtoken, desktop, stDesktop) || + CheckVersionFlag(kOsVersion, wtoken, osVersion, stOsVersion) || + CheckVersionFlag(kAppVersion, wtoken, appVersion, stAppVersion) || + CheckVersionFlag(kGeckoVersion, wtoken, geckoVersion, stGeckoVersion)) + continue; + + #if defined(MOZ_WIDGET_ANDROID) + bool tablet = false; + if (CheckFlag(kTablet, wtoken, tablet)) { +@@ -639,16 +648,17 @@ ParseManifest(NSLocationType type, FileL + } + + if (!ok || + stApp == eBad || + stAppVersion == eBad || + stGeckoVersion == eBad || + stOs == eBad || + stOsVersion == eBad || ++ stDesktop == eBad || + #ifdef MOZ_WIDGET_ANDROID + stTablet == eBad || + #endif + stABI == eBad) + continue; + + if (directive->regfunc) { + if (GeckoProcessType_Default != XRE_GetProcessType()) diff --git a/xpcom/io/Makefile.in b/xpcom/io/Makefile.in --- a/xpcom/io/Makefile.in +++ b/xpcom/io/Makefile.in @@ -3790,7 +3795,7 @@ diff --git a/xpcom/io/nsLocalFileUnix.cpp b/xpcom/io/nsLocalFileUnix.cpp #include "prmem.h" #include "plbase64.h" -@@ -1795,44 +1796,51 @@ nsLocalFile::SetPersistentDescriptor(con +@@ -1796,44 +1797,51 @@ nsLocalFile::SetPersistentDescriptor(con return InitWithNativePath(aPersistentDescriptor); #endif } @@ -3856,7 +3861,7 @@ diff --git a/xpcom/io/nsLocalFileUnix.cpp b/xpcom/io/nsLocalFileUnix.cpp return rv; } return NS_ERROR_FAILURE; -@@ -1858,16 +1866,23 @@ nsLocalFile::Launch() +@@ -1859,16 +1867,23 @@ nsLocalFile::Launch() if (nsnull == connection) return NS_ERROR_FAILURE; diff --git a/mozilla-nongnome-proxies.patch b/mozilla-nongnome-proxies.patch index b1fae8b..8d20df5 100644 --- a/mozilla-nongnome-proxies.patch +++ b/mozilla-nongnome-proxies.patch @@ -9,7 +9,7 @@ retrieving revision 1.1 diff --git a/toolkit/system/unixproxy/nsUnixSystemProxySettings.cpp b/toolkit/system/unixproxy/nsUnixSystemProxySettings.cpp --- a/toolkit/system/unixproxy/nsUnixSystemProxySettings.cpp +++ b/toolkit/system/unixproxy/nsUnixSystemProxySettings.cpp -@@ -71,18 +71,24 @@ private: +@@ -74,22 +74,28 @@ private: nsresult SetProxyResultFromGSettings(const char* aKeyBase, const char* aType, nsACString& aResult); }; @@ -18,21 +18,29 @@ diff --git a/toolkit/system/unixproxy/nsUnixSystemProxySettings.cpp b/toolkit/sy nsresult nsUnixSystemProxySettings::Init() { +- mSchemeProxySettings.Init(5); - mGConf = do_GetService(NS_GCONFSERVICE_CONTRACTID); - mGSettings = do_GetService(NS_GSETTINGSSERVICE_CONTRACTID); +- if (mGSettings) { +- mGSettings->GetCollectionForSchema(NS_LITERAL_CSTRING("org.gnome.system.proxy"), +- getter_AddRefs(mProxySettings)); + // If this is a GNOME session, load gconf and try to use its preferences. + // If gconf is not available (which would be stupid) we'll proceed as if + // this was not a GNOME session, using *_PROXY environment variables. + const char* sessionType = PR_GetEnv("DESKTOP_SESSION"); + if (sessionType && !strcmp(sessionType, "gnome")) { ++ mSchemeProxySettings.Init(5); + mGConf = do_GetService(NS_GCONFSERVICE_CONTRACTID); + mGSettings = do_GetService(NS_GSETTINGSSERVICE_CONTRACTID); -+ } ++ if (mGSettings) { ++ mGSettings->GetCollectionForSchema(NS_LITERAL_CSTRING("org.gnome.system.proxy"), ++ getter_AddRefs(mProxySettings)); ++ } + } + return NS_OK; } bool nsUnixSystemProxySettings::IsProxyMode(const char* aMode) { - nsCAutoString mode; - return NS_SUCCEEDED(mGConf->GetString(NS_LITERAL_CSTRING("/system/proxy/mode"), mode)) && diff --git a/mozilla-nsSound.patch b/mozilla-nsSound.patch new file mode 100644 index 0000000..ba0808c --- /dev/null +++ b/mozilla-nsSound.patch @@ -0,0 +1,43 @@ + +# HG changeset patch +# User Wolfgang Rosenauer +# Date 1336632642 -7200 +# Node ID 56cc5a3c431612fa98f0550f02a9f34b566e1d9b +# Parent 307671d73258761245d165e43591d885c7f68b73 +Bug 749739 - New email sound notification file cannot contain spaces (Linux - Thunderbird 12). r=karlt, a=lsblakk (upstream in FF14) + +diff --git a/widget/gtk2/nsSound.cpp b/widget/gtk2/nsSound.cpp +--- a/widget/gtk2/nsSound.cpp ++++ b/widget/gtk2/nsSound.cpp +@@ -353,23 +353,28 @@ NS_METHOD nsSound::Play(nsIURL *aURL) + bool isFile; + nsresult rv = aURL->SchemeIs("file", &isFile); + if (NS_SUCCEEDED(rv) && isFile) { + ca_context* ctx = ca_context_get_default(); + if (!ctx) { + return NS_ERROR_OUT_OF_MEMORY; + } + +- nsCAutoString path; +- rv = aURL->GetPath(path); ++ nsCAutoString spec; ++ rv = aURL->GetSpec(spec); + if (NS_FAILED(rv)) { + return rv; + } ++ gchar *path = g_filename_from_uri(spec.get(), NULL, NULL); ++ if (!path) { ++ return NS_ERROR_FILE_UNRECOGNIZED_PATH; ++ } + +- ca_context_play(ctx, 0, "media.filename", path.get(), NULL); ++ ca_context_play(ctx, 0, "media.filename", path, NULL); ++ g_free(path); + } else { + nsCOMPtr loader; + rv = NS_NewStreamLoader(getter_AddRefs(loader), aURL, this); + } + + return rv; + } + diff --git a/mozilla-repo.patch b/mozilla-repo.patch index 0466696..ee0e23a 100644 --- a/mozilla-repo.patch +++ b/mozilla-repo.patch @@ -1,20 +1,20 @@ # HG changeset patch -# Parent 8ea0f829916d7d9dc54567813367bcdfe6cee179 +# Parent 271b5143e89573cbbde51d0b830a6116756a52e6 diff --git a/build/Makefile.in b/build/Makefile.in --- a/build/Makefile.in +++ b/build/Makefile.in -@@ -91,17 +91,17 @@ DEFINES += -DMOZ_APP_VERSION="$(MOZ_APP_ +@@ -89,17 +89,17 @@ DEFINES += -DMOZ_APP_VERSION="$(MOZ_APP_ APP_INI_DEPS += $(DEPTH)/config/autoconf.mk - MOZ_SOURCE_STAMP ?= $(firstword $(shell hg -R $(topsrcdir) parent --template="{node|short}\n" 2>/dev/null)) + MOZ_SOURCE_STAMP := $(firstword $(shell cd $(topsrcdir)/$(MOZ_BUILD_APP)/.. && hg parent --template="{node|short}\n" 2>/dev/null)) ifdef MOZ_SOURCE_STAMP DEFINES += -DMOZ_SOURCE_STAMP="$(MOZ_SOURCE_STAMP)" endif _dollar=$$ --SOURCE_REPO := $(shell cd $(topsrcdir) && hg showconfig paths.default 2>/dev/null | head -n1 | sed -e "s/^ssh:/http:/" -e "s/\/$(_dollar)//" ) -+SOURCE_REPO ?= $(shell cd $(topsrcdir) && hg showconfig paths.default 2>/dev/null | head -n1 | sed -e "s/^ssh:/http:/" -e "s/\/$(_dollar)//" ) +-SOURCE_REPO := $(shell cd $(topsrcdir)/$(MOZ_BUILD_APP)/.. && hg showconfig paths.default 2>/dev/null | head -n1 | sed -e "s/^ssh:/http:/" -e "s/\/$(_dollar)//" ) ++SOURCE_REPO ?= $(shell cd $(topsrcdir)/$(MOZ_BUILD_APP)/.. && hg showconfig paths.default 2>/dev/null | head -n1 | sed -e "s/^ssh:/http:/" -e "s/\/$(_dollar)//" ) ifdef SOURCE_REPO DEFINES += -DMOZ_SOURCE_REPO="$(SOURCE_REPO)" endif @@ -26,7 +26,7 @@ diff --git a/build/Makefile.in b/build/Makefile.in diff --git a/toolkit/content/Makefile.in b/toolkit/content/Makefile.in --- a/toolkit/content/Makefile.in +++ b/toolkit/content/Makefile.in -@@ -65,17 +65,17 @@ endif +@@ -67,17 +67,17 @@ endif ifeq (Android,$(OS_TARGET)) DEFINES += -DANDROID_PACKAGE_NAME=$(ANDROID_PACKAGE_NAME) endif @@ -43,8 +43,8 @@ diff --git a/toolkit/content/Makefile.in b/toolkit/content/Makefile.in DEFINES += -DSOURCE_REPO="$(SOURCE_REPO)" endif - ifdef MOZ_TOOLKIT_SEARCH - DEFINES += -DMOZ_TOOLKIT_SEARCH + BUILD_HOSTNAME = $(shell hostname -s || hostname) + DEFINES += -DBUILD_HOSTNAME="$(BUILD_HOSTNAME)" diff --git a/toolkit/mozapps/installer/package-name.mk b/toolkit/mozapps/installer/package-name.mk --- a/toolkit/mozapps/installer/package-name.mk +++ b/toolkit/mozapps/installer/package-name.mk @@ -74,7 +74,7 @@ diff --git a/toolkit/mozapps/installer/package-name.mk b/toolkit/mozapps/install diff --git a/toolkit/xre/Makefile.in b/toolkit/xre/Makefile.in --- a/toolkit/xre/Makefile.in +++ b/toolkit/xre/Makefile.in -@@ -236,17 +236,17 @@ DEFINES += -DHAVE_USR_LIB64_DIR +@@ -229,17 +229,17 @@ DEFINES += -DHAVE_USR_LIB64_DIR endif endif diff --git a/mozilla-system-nspr.patch b/mozilla-system-nspr.patch new file mode 100644 index 0000000..eadf0c6 --- /dev/null +++ b/mozilla-system-nspr.patch @@ -0,0 +1,27 @@ +# HG changeset patch +# User Wolfgang Rosenauer +# Parent e94edfdb1f5bd5c29dc54cfb83768f9c84f3f4de +Bug 736854 - PHal.ipdl includes NSPR incorrectly - breaking system NSPR usage + +diff --git a/hal/sandbox/PHal.ipdl b/hal/sandbox/PHal.ipdl +--- a/hal/sandbox/PHal.ipdl ++++ b/hal/sandbox/PHal.ipdl +@@ -34,17 +34,17 @@ + * and other provisions required by the GPL or the LGPL. If you do not delete + * the provisions above, a recipient may use your version of this file under + * the terms of any one of the MPL, the GPL or the LGPL. + * + * ***** END LICENSE BLOCK ***** */ + + include protocol PContent; + include protocol PBrowser; +-include "nspr/prtime.h"; ++include "prtime.h"; + include "mozilla/HalSensor.h"; + include "mozilla/HalTypes.h"; + + using PRTime; + using mozilla::hal::FlashMode; + using mozilla::hal::LightType; + using mozilla::hal::LightMode; + using mozilla::hal::SensorType; diff --git a/mozilla-yarr-pcre.patch b/mozilla-yarr-pcre.patch index de2101d..374f793 100644 --- a/mozilla-yarr-pcre.patch +++ b/mozilla-yarr-pcre.patch @@ -1,40 +1,42 @@ -# HG changeset patch -# Parent 58dd942011a81f3149d9bc34e808806bda099056 -# User Landry Breuil -Use YARR interpreter instead of PCRE on platforms where YARR JIT is not -supported - diff --git a/js/src/Makefile.in b/js/src/Makefile.in --- a/js/src/Makefile.in +++ b/js/src/Makefile.in -@@ -335,25 +335,29 @@ CPPSRCS += checks.cc \ +@@ -332,30 +332,33 @@ CPPSRCS += checks.cc \ + platform.cc \ + utils.cc \ + $(NONE) + + # # END enclude sources for V8 dtoa ############################################# - # For architectures without YARR JIT, PCRE is faster than the YARR - # interpreter (bug 684559). - +-# For architectures without YARR JIT, PCRE is faster than the YARR +-# interpreter (bug 684559). +- ifeq (,$(filter arm% sparc %86 x86_64 mips%,$(TARGET_CPU))) -VPATH += $(srcdir)/yarr/pcre \ -+VPATH += $(srcdir)/assembler \ -+ $(srcdir)/assembler/wtf \ -+ $(srcdir)/yarr \ ++VPATH += $(srcdir)/assembler \ ++ $(srcdir)/assembler/wtf \ ++ $(srcdir)/assembler/jit \ ++ $(srcdir)/yarr \ $(NULL) - CPPSRCS += \ +-CPPSRCS += \ - pcre_compile.cpp \ - pcre_exec.cpp \ - pcre_tables.cpp \ - pcre_xclass.cpp \ - pcre_ucp_searchfuncs.cpp \ -+ OSAllocatorOS2.cpp \ -+ OSAllocatorPosix.cpp \ -+ OSAllocatorWin.cpp \ -+ PageBlock.cpp \ -+ YarrInterpreter.cpp \ -+ YarrPattern.cpp \ -+ YarrSyntaxChecker.cpp \ ++CPPSRCS += ExecutableAllocator.cpp \ ++ ExecutableAllocatorPosix.cpp \ ++ OSAllocatorOS2.cpp \ ++ OSAllocatorPosix.cpp \ ++ OSAllocatorWin.cpp \ ++ PageBlock.cpp \ ++ YarrInterpreter.cpp \ ++ YarrPattern.cpp \ ++ YarrSyntaxChecker.cpp \ $(NULL) else @@ -43,203 +45,32 @@ diff --git a/js/src/Makefile.in b/js/src/Makefile.in # ENABLE_YARR_JIT = 1 -@@ -878,20 +882,20 @@ endif - - ############################################### - # BEGIN kludges for the Nitro assembler - # - - # Needed to "configure" it correctly. Unfortunately these - # flags wind up being applied to all code in js/src, not just - # the code in js/src/assembler. --CXXFLAGS += -DUSE_SYSTEM_MALLOC=1 -DENABLE_ASSEMBLER=1 -+CXXFLAGS += -DUSE_SYSTEM_MALLOC=1 - - ifneq (,$(ENABLE_YARR_JIT)$(ENABLE_METHODJIT)) --CXXFLAGS += -DENABLE_JIT=1 -+CXXFLAGS += -DENABLE_JIT=1 -DENABLE_ASSEMBLER=1 - endif - - INCLUDES += -I$(srcdir)/assembler -I$(srcdir)/yarr - - ifdef ENABLE_METHODJIT - # Build a standalone test program that exercises the assembler - # sources a bit. - TESTMAIN_OBJS = \ -diff --git a/js/src/jsapi.cpp b/js/src/jsapi.cpp ---- a/js/src/jsapi.cpp -+++ b/js/src/jsapi.cpp -@@ -696,17 +696,19 @@ JS_IsBuiltinFunctionConstructor(JSFuncti - static JSBool js_NewRuntimeWasCalled = JS_FALSE; - - JSRuntime::JSRuntime() - : atomsCompartment(NULL), - #ifdef JS_THREADSAFE - ownerThread_(NULL), +diff --git a/js/src/assembler/jit/ExecutableAllocator.h b/js/src/assembler/jit/ExecutableAllocator.h +--- a/js/src/assembler/jit/ExecutableAllocator.h ++++ b/js/src/assembler/jit/ExecutableAllocator.h +@@ -462,18 +462,16 @@ public: + : "r" (code), "r" (reinterpret_cast(code) + size) + : "r0", "r1", "r2"); + } + #elif WTF_CPU_SPARC + static void cacheFlush(void* code, size_t size) + { + sync_instruction_memory((caddr_t)code, size); + } +-#else +- #error "The cacheFlush support is missing on this platform." #endif - tempLifoAlloc(TEMP_LIFO_ALLOC_PRIMARY_CHUNK_SIZE), -+#if ENABLE_ASSEMBLER - execAlloc_(NULL), -+#endif - bumpAlloc_(NULL), - nativeStackBase(0), - nativeStackQuota(0), - interpreterFrames(NULL), - cxCallback(NULL), - compartmentCallback(NULL), - activityCallback(NULL), - activityCallbackArg(NULL), -@@ -851,17 +853,19 @@ JSRuntime::init(uint32_t maxbytes) - nativeStackBase = GetNativeStackBase(); - return true; - } - JSRuntime::~JSRuntime() - { - JS_ASSERT(onOwnerThread()); + private: -+#if ENABLE_ASSEMBLER - delete_(execAlloc_); -+#endif - delete_(bumpAlloc_); - - #ifdef DEBUG - /* Don't hurt everyone in leaky ol' Mozilla with a fatal JS_ASSERT! */ - if (!JS_CLIST_IS_EMPTY(&contextList)) { - JSContext *cx, *iter = NULL; - uintN cxcount = 0; - while ((cx = js_ContextIterator(this, JS_TRUE, &iter)) != NULL) { -diff --git a/js/src/jscntxt.cpp b/js/src/jscntxt.cpp ---- a/js/src/jscntxt.cpp -+++ b/js/src/jscntxt.cpp -@@ -100,19 +100,21 @@ JSRuntime::sizeOfExcludingThis(JSMallocS - if (normal) - *normal = mallocSizeOf(dtoaState); - - if (temporary) - *temporary = tempLifoAlloc.sizeOfExcludingThis(mallocSizeOf); - - if (regexpCode) { - size_t method = 0, regexp = 0, unused = 0; -+#if ENABLE_ASSEMBLER - if (execAlloc_) - execAlloc_->sizeOfCode(&method, ®exp, &unused); - JS_ASSERT(method == 0); /* this execAlloc is only used for regexp code */ -+#endif - *regexpCode = regexp + unused; - } - - if (stackCommitted) - *stackCommitted = stackSpace.sizeOfCommitted(); - } - - JS_FRIEND_API(void) -@@ -124,33 +126,37 @@ JSRuntime::triggerOperationCallback() - */ - JS_ATOMIC_SET(&interrupt, 1); - } - - void - JSRuntime::setJitHardening(bool enabled) - { - jitHardening = enabled; -+#if ENABLE_ASSEMBLER - if (execAlloc_) - execAlloc_->setRandomize(enabled); -+#endif - } - -+#if ENABLE_ASSEMBLER - JSC::ExecutableAllocator * - JSRuntime::createExecutableAllocator(JSContext *cx) - { - JS_ASSERT(!execAlloc_); - JS_ASSERT(cx->runtime == this); - - JSC::AllocationBehavior randomize = - jitHardening ? JSC::AllocationCanRandomize : JSC::AllocationDeterministic; - execAlloc_ = new_(randomize); - if (!execAlloc_) - js_ReportOutOfMemory(cx); - return execAlloc_; - } -+#endif - - WTF::BumpPointerAllocator * - JSRuntime::createBumpPointerAllocator(JSContext *cx) - { - JS_ASSERT(!bumpAlloc_); - JS_ASSERT(cx->runtime == this); - - bumpAlloc_ = new_(); -diff --git a/js/src/jscntxt.h b/js/src/jscntxt.h ---- a/js/src/jscntxt.h -+++ b/js/src/jscntxt.h -@@ -219,26 +219,32 @@ struct JSRuntime : js::RuntimeFriendFiel - static const size_t TEMP_LIFO_ALLOC_PRIMARY_CHUNK_SIZE = 1 << 12; - js::LifoAlloc tempLifoAlloc; - - private: - /* - * Both of these allocators are used for regular expression code which is shared at the - * thread-data level. - */ -+#if ENABLE_ASSEMBLER - JSC::ExecutableAllocator *execAlloc_; -+#endif - WTF::BumpPointerAllocator *bumpAlloc_; - -+#if ENABLE_ASSEMBLER - JSC::ExecutableAllocator *createExecutableAllocator(JSContext *cx); -+#endif - WTF::BumpPointerAllocator *createBumpPointerAllocator(JSContext *cx); - - public: -+#if ENABLE_ASSEMBLER - JSC::ExecutableAllocator *getExecutableAllocator(JSContext *cx) { - return execAlloc_ ? execAlloc_ : createExecutableAllocator(cx); - } -+#endif - WTF::BumpPointerAllocator *getBumpPointerAllocator(JSContext *cx) { - return bumpAlloc_ ? bumpAlloc_ : createBumpPointerAllocator(cx); - } - - /* Base address of the native stack for the current thread. */ - uintptr_t nativeStackBase; - - /* The native stack size limit that runtime should not exceed. */ -diff --git a/js/src/jsprvtd.h b/js/src/jsprvtd.h ---- a/js/src/jsprvtd.h -+++ b/js/src/jsprvtd.h -@@ -313,22 +313,23 @@ typedef Handle Handl - typedef Handle HandleTypeObject; - typedef Handle HandleString; - typedef Handle HandleAtom; - typedef Handle HandleId; - typedef Handle HandleValue; - - } /* namespace js */ - -+#if ENABLE_ASSEMBLER - namespace JSC { - - class ExecutableAllocator; - - } /* namespace JSC */ -- -+#endif - namespace WTF { - - class BumpPointerAllocator; - - } /* namespace WTF */ - - } /* export "C++" */ + #if ENABLE_ASSEMBLER_WX_EXCLUSIVE + static void reprotectRegion(void*, size_t, ProtectionSetting); + #endif diff --git a/js/src/vm/RegExpObject-inl.h b/js/src/vm/RegExpObject-inl.h --- a/js/src/vm/RegExpObject-inl.h +++ b/js/src/vm/RegExpObject-inl.h -@@ -132,26 +132,28 @@ RegExpObject::setMultiline(bool enabled) +@@ -132,16 +132,17 @@ RegExpObject::setMultiline(bool enabled) } inline void @@ -257,17 +88,6 @@ diff --git a/js/src/vm/RegExpObject-inl.h b/js/src/vm/RegExpObject-inl.h return cx->methodJitEnabled; #else return true; - #endif - } -+#endif - - inline bool - RegExpToShared(JSContext *cx, JSObject &obj, RegExpGuard *g) - { - JS_ASSERT(ObjectClassIs(obj, ESClass_RegExp, cx)); - if (obj.isRegExp()) - return obj.asRegExp().getShared(cx, g); - return Proxy::regexp_toShared(cx, &obj, g); diff --git a/js/src/vm/RegExpObject.cpp b/js/src/vm/RegExpObject.cpp --- a/js/src/vm/RegExpObject.cpp +++ b/js/src/vm/RegExpObject.cpp @@ -289,7 +109,7 @@ diff --git a/js/src/vm/RegExpObject.cpp b/js/src/vm/RegExpObject.cpp JS_NOT_REACHED("Called reportYarrError with value for no error"); return; #define COMPILE_EMSG(__code, __msg) \ -@@ -194,73 +193,36 @@ RegExpCode::reportYarrError(JSContext *c +@@ -194,52 +193,16 @@ RegExpCode::reportYarrError(JSContext *c COMPILE_EMSG(QuantifierTooLarge, JSMSG_BAD_QUANTIFIER); COMPILE_EMSG(EscapeUnterminated, JSMSG_TRAILING_SLASH); #undef COMPILE_EMSG @@ -335,97 +155,13 @@ diff --git a/js/src/vm/RegExpObject.cpp b/js/src/vm/RegExpObject.cpp -#endif /* ENABLE_YARR_JIT */ - bool - RegExpCode::compile(JSContext *cx, JSLinearString &pattern, uintN *parenCount, RegExpFlag flags) + RegExpCode::compile(JSContext *cx, JSLinearString &pattern, unsigned *parenCount, RegExpFlag flags) { --#if ENABLE_YARR_JIT + #if ENABLE_YARR_JIT /* Parse the pattern. */ ErrorCode yarrError; YarrPattern yarrPattern(pattern, bool(flags & IgnoreCaseFlag), bool(flags & MultilineFlag), &yarrError); - if (yarrError) { - reportYarrError(cx, NULL, yarrError); - return false; - } - *parenCount = yarrPattern.m_numSubpatterns; - - /* - * The YARR JIT compiler attempts to compile the parsed pattern. If - * it cannot, it informs us via |codeBlock.isFallBack()|, in which - * case we have to bytecode compile it. - */ - --#ifdef JS_METHODJIT -+#if ENABLE_YARR_JIT && defined(JS_METHODJIT) - if (isJITRuntimeEnabled(cx) && !yarrPattern.m_containsBackreferences) { - JSC::ExecutableAllocator *execAlloc = cx->runtime->getExecutableAllocator(cx); - if (!execAlloc) { - js_ReportOutOfMemory(cx); - return false; - } - - JSGlobalData globalData(execAlloc); -@@ -271,58 +233,41 @@ RegExpCode::compile(JSContext *cx, JSLin - #endif - - WTF::BumpPointerAllocator *bumpAlloc = cx->runtime->getBumpPointerAllocator(cx); - if (!bumpAlloc) { - js_ReportOutOfMemory(cx); - return false; - } - -+#if ENABLE_YARR_JIT - codeBlock.setFallBack(true); -+#endif - byteCode = byteCompile(yarrPattern, bumpAlloc).get(); - return true; --#else /* !defined(ENABLE_YARR_JIT) */ -- int error = 0; -- compiled = jsRegExpCompile(pattern.chars(), pattern.length(), -- ignoreCase() ? JSRegExpIgnoreCase : JSRegExpDoNotIgnoreCase, -- multiline() ? JSRegExpMultiline : JSRegExpSingleLine, -- parenCount, &error); -- if (error) { -- reportPCREError(cx, error); -- return false; -- } -- return true; --#endif - } - - RegExpRunStatus - RegExpCode::execute(JSContext *cx, const jschar *chars, size_t length, size_t start, - int *output, size_t outputCount) - { - int result; - #if ENABLE_YARR_JIT - (void) cx; /* Unused. */ - if (codeBlock.isFallBack()) - result = JSC::Yarr::interpret(byteCode, chars, start, length, output); - else - result = JSC::Yarr::execute(codeBlock, chars, start, length, output); - #else -- result = jsRegExpExecute(cx, compiled, chars, length, start, output, outputCount); -+ result = JSC::Yarr::interpret(byteCode, chars, start, length, output); - #endif - - if (result == -1) - return RegExpRunStatus_Success_NotFound; - --#if !ENABLE_YARR_JIT -- if (result < 0) { -- reportPCREError(cx, result); -- return RegExpRunStatus_Error; -- } --#endif -- - JS_ASSERT(result >= 0); - return RegExpRunStatus_Success; - } - - /* RegExpObject */ - - static void - regexp_trace(JSTracer *trc, JSObject *obj) diff --git a/js/src/vm/RegExpObject.h b/js/src/vm/RegExpObject.h --- a/js/src/vm/RegExpObject.h +++ b/js/src/vm/RegExpObject.h @@ -451,91 +187,6 @@ diff --git a/js/src/vm/RegExpObject.h b/js/src/vm/RegExpObject.h * * RegExpObject - The JS-visible object whose .[[Class]] equals "RegExp" * -@@ -107,78 +105,61 @@ class RegExpObjectBuilder - - JSObject * - CloneRegExpObject(JSContext *cx, JSObject *obj, JSObject *proto); - - namespace detail { - - class RegExpCode - { --#if ENABLE_YARR_JIT - typedef JSC::Yarr::BytecodePattern BytecodePattern; - typedef JSC::Yarr::ErrorCode ErrorCode; -+ typedef JSC::Yarr::YarrPattern YarrPattern; -+#if ENABLE_YARR_JIT - typedef JSC::Yarr::JSGlobalData JSGlobalData; - typedef JSC::Yarr::YarrCodeBlock YarrCodeBlock; -- typedef JSC::Yarr::YarrPattern YarrPattern; - - /* Note: Native code is valid only if |codeBlock.isFallBack() == false|. */ - YarrCodeBlock codeBlock; -+#endif - BytecodePattern *byteCode; --#else -- JSRegExp *compiled; --#endif - - public: - RegExpCode() - : - #if ENABLE_YARR_JIT - codeBlock(), -+#endif - byteCode(NULL) --#else -- compiled(NULL) --#endif - { } - - ~RegExpCode() { - #if ENABLE_YARR_JIT - codeBlock.release(); -+#endif - if (byteCode) - Foreground::delete_(byteCode); --#else -- if (compiled) -- jsRegExpFree(compiled); --#endif - } - - static bool checkSyntax(JSContext *cx, TokenStream *tokenStream, JSLinearString *source) { --#if ENABLE_YARR_JIT - ErrorCode error = JSC::Yarr::checkSyntax(*source); - if (error == JSC::Yarr::NoError) - return true; - - reportYarrError(cx, tokenStream, error); - return false; --#else --# error "Syntax checking not implemented for !ENABLE_YARR_JIT" --#endif - } - - #if ENABLE_YARR_JIT - static inline bool isJITRuntimeEnabled(JSContext *cx); -+#endif - static void reportYarrError(JSContext *cx, TokenStream *ts, JSC::Yarr::ErrorCode error); --#else -- static void reportPCREError(JSContext *cx, int error); --#endif - - static size_t getOutputSize(size_t pairCount) { --#if ENABLE_YARR_JIT - return pairCount * 2; --#else -- return pairCount * 3; /* Should be x2, but PCRE has... needs. */ --#endif - } - - bool compile(JSContext *cx, JSLinearString &pattern, uintN *parenCount, RegExpFlag flags); - - - RegExpRunStatus - execute(JSContext *cx, const jschar *chars, size_t length, size_t start, - int *output, size_t outputCount); diff --git a/js/src/yarr/wtfbridge.h b/js/src/yarr/wtfbridge.h --- a/js/src/yarr/wtfbridge.h +++ b/js/src/yarr/wtfbridge.h diff --git a/source-stamp.txt b/source-stamp.txt index d0aba78..d89b912 100644 --- a/source-stamp.txt +++ b/source-stamp.txt @@ -1,2 +1,2 @@ -REV=a294a5b4f12d +REV=2b643ea8edf9 REPO=http://hg.mozilla.org/releases/mozilla-release