#546 and #548: M1503393 M1524214 M1524755 M1525145 M1516754 M1518774 M1524264 M1530103 M1531277

This commit is contained in:
Cameron Kaiser 2019-03-15 21:06:16 -07:00
parent dcccda4e6a
commit eb7532fd4d
15 changed files with 3221 additions and 1345 deletions

View File

@ -76,7 +76,7 @@ var gConnectionsDialog = {
var autologinProxyPref = document.getElementById("signon.autologin.proxy");
autologinProxyPref.disabled = proxyTypePref.value == 0;
var noProxiesPref = document.getElementById("network.proxy.no_proxies_on");
noProxiesPref.disabled = proxyTypePref.value != 1;
noProxiesPref.disabled = proxyTypePref.value == 0;
var autoconfigURLPref = document.getElementById("network.proxy.autoconfig_url");
autoconfigURLPref.disabled = proxyTypePref.value != 2;

View File

@ -146,9 +146,6 @@
<checkbox id="networkProxySOCKSRemoteDNS" preference="network.proxy.socks_remote_dns" label="&socksRemoteDNS.label;" accesskey="&socksRemoteDNS.accesskey;" />
</box>
</row>
<label value="&noproxy.label;" accesskey="&noproxy.accesskey;" control="networkProxyNone"/>
<textbox id="networkProxyNone" preference="network.proxy.no_proxies_on" multiline="true" rows="2"/>
<label value="&noproxyExplain.label;" control="networkProxyNone"/>
</rows>
</grid>
<radio value="2" label="&autoTypeRadio.label;" accesskey="&autoTypeRadio.accesskey;"/>
@ -163,6 +160,9 @@
</radiogroup>
</groupbox>
<separator class="thin"/>
<label value="&noproxy.label;" accesskey="&noproxy.accesskey;" control="networkProxyNone"/>
<textbox id="networkProxyNone" preference="network.proxy.no_proxies_on" multiline="true" rows="2"/>
<label value="&noproxyExplain.label;" control="networkProxyNone"/>
<checkbox id="autologinProxy"
label="&autologinproxy.label;"
accesskey="&autologinproxy.accesskey;"

View File

@ -388,11 +388,10 @@ HTMLTableElement::CreateTHead()
void
HTMLTableElement::DeleteTHead()
{
HTMLTableSectionElement* tHead = GetTHead();
RefPtr<HTMLTableSectionElement> tHead = GetTHead();
if (tHead) {
mozilla::ErrorResult rv;
mozilla::IgnoredErrorResult rv;
nsINode::RemoveChild(*tHead, rv);
MOZ_ASSERT(!rv.Failed());
}
}
@ -419,11 +418,10 @@ HTMLTableElement::CreateTFoot()
void
HTMLTableElement::DeleteTFoot()
{
HTMLTableSectionElement* tFoot = GetTFoot();
RefPtr<HTMLTableSectionElement> tFoot = GetTFoot();
if (tFoot) {
mozilla::ErrorResult rv;
mozilla::IgnoredErrorResult rv;
nsINode::RemoveChild(*tFoot, rv);
MOZ_ASSERT(!rv.Failed());
}
}
@ -450,11 +448,10 @@ HTMLTableElement::CreateCaption()
void
HTMLTableElement::DeleteCaption()
{
HTMLTableCaptionElement* caption = GetCaption();
RefPtr<HTMLTableCaptionElement> caption = GetCaption();
if (caption) {
mozilla::ErrorResult rv;
mozilla::IgnoredErrorResult rv;
nsINode::RemoveChild(*caption, rv);
MOZ_ASSERT(!rv.Failed());
}
}

View File

@ -122,7 +122,7 @@ HTMLTableSectionElement::DeleteRow(int32_t aValue, ErrorResult& aError)
refIndex = (uint32_t)aValue;
}
nsINode* row = rows->Item(refIndex);
nsCOMPtr<nsINode> row = rows->Item(refIndex);
if (!row) {
aError.Throw(NS_ERROR_DOM_INDEX_SIZE_ERR);
return;

View File

@ -330,6 +330,7 @@ TrackBuffersManager::CompleteResetParserState()
}
// 7. Remove all bytes from the input buffer.
mPendingInputBuffer = nullptr;
mIncomingBuffers.Clear();
mInputBuffer = nullptr;
if (mCurrentInputBuffer) {

View File

@ -28,6 +28,14 @@ MiniMP3Decoder::MiniMP3Decoder(const AudioInfo& aConfig,
#error Unknown audio sample type
#endif
// Correctness fix from
// https://github.com/OlgaTPark/tenfourfox/commit/a22d83f6b190a71386fe193ee1f3f08dc1639d39
mMP3Decoder.last_buf_size = 0;
memset(mMP3Decoder.synth_buf_offset, 0, sizeof(mMP3Decoder.synth_buf_offset));
// Ensure buffers are clear to avoid decoding artifacts.
memset(mMP3Decoder.mdct_buf, 0, sizeof(mMP3Decoder.mdct_buf));
memset(mMP3Decoder.synth_buf, 0, sizeof(mMP3Decoder.synth_buf));
#if DEBUG
fprintf(stderr, "MiniMP3Decoder::MiniMP3Decoder\n");
#endif

View File

@ -233,7 +233,7 @@ void
nsSMILAnimationController::NotifyRefreshDriverCreated(
nsRefreshDriver* aRefreshDriver)
{
if (!mPauseState) {
if (!mPauseState && mChildContainerTable.Count()) {
MaybeStartSampling(aRefreshDriver);
}
}

View File

@ -7107,7 +7107,8 @@ PresShell::HandleEvent(nsIFrame* aFrame,
return NS_OK;
}
nsIContent* capturingContent = ((aEvent->mClass == ePointerEventClass ||
nsCOMPtr<nsIContent> capturingContent
= ((aEvent->mClass == ePointerEventClass ||
aEvent->mClass == eWheelEventClass ||
aEvent->HasMouseEventMessage())
? GetCapturingContent()

View File

@ -207,7 +207,7 @@ public:
return *this;
}
T& operator[](int aIndex) const
T& operator[](ptrdiff_t aIndex) const
{
MOZ_ASSERT(size_t(aIndex > 0 ? aIndex : -aIndex) <= size_t(-1) / sizeof(T));
return *create(mPtr + aIndex);

View File

@ -1795,6 +1795,12 @@ nsProtocolProxyService::Resolve_Internal(nsIChannel *channel,
if (mPACMan && mPACMan->IsPACURI(uri))
return NS_OK;
// if proxies are enabled and this host:port combo is supposed to use a
// proxy, check for a proxy.
if ((mProxyConfig == PROXYCONFIG_DIRECT) ||
!CanUseProxy(uri, info.defaultPort))
return NS_OK;
bool mainThreadOnly;
if (mSystemProxySettings &&
mProxyConfig == PROXYCONFIG_SYSTEM &&

View File

@ -4659,9 +4659,6 @@ web.ni
// ccTLD for the Netherlands
nl
// BV.nl will be a registry for dutch BV's (besloten vennootschap)
bv.nl
// no : http://www.norid.no/regelverk/index.en.html
// The Norwegian registry has declined to notify us of updates. The web pages
// referenced below are the official source of the data. There is also an
@ -7107,9 +7104,6 @@ accountants
// aco : 2015-01-08 ACO Severin Ahlmann GmbH & Co. KG
aco
// active : 2014-05-01 Active Network, LLC
active
// actor : 2013-12-12 United TLD Holdco Ltd.
actor
@ -7410,9 +7404,6 @@ black
// blackfriday : 2014-01-16 Uniregistry, Corp.
blackfriday
// blanco : 2015-07-16 BLANCO GmbH + Co KG
blanco
// blockbuster : 2015-07-30 Dish DBS Corporation
blockbuster
@ -8022,9 +8013,6 @@ engineering
// enterprises : 2013-09-20 Binky Moon, LLC
enterprises
// epost : 2015-07-23 Deutsche Post AG
epost
// epson : 2014-12-04 Seiko Epson Corporation
epson
@ -9846,9 +9834,6 @@ soy
// space : 2014-04-03 DotSpace Inc.
space
// spiegel : 2014-02-05 SPIEGEL-Verlag Rudolf Augstein GmbH & Co. KG
spiegel
// sport : 2017-11-16 Global Association of International Sports Federations (GAISF)
sport
@ -10683,9 +10668,6 @@ zero
// zip : 2014-05-08 Charleston Road Registry Inc.
zip
// zippo : 2015-07-02 Zadco Company
zippo
// zone : 2013-11-14 Binky Moon, LLC
zone
@ -11639,6 +11621,7 @@ channelsdvr.net
// Fastly Inc. : http://www.fastly.com/
// Submitted by Fastly Security <security@fastly.com>
fastly-terrarium.com
fastlylb.net
map.fastlylb.net
freetls.fastly.net
@ -11673,6 +11656,12 @@ mydobiss.com
// Filegear Inc. : https://www.filegear.com
// Submitted by Jason Zhu <jason@owtware.com>
filegear.me
filegear-au.me
filegear-de.me
filegear-gb.me
filegear-ie.me
filegear-jp.me
filegear-sg.me
// Firebase, Inc.
// Submitted by Chris Raynor <chris@firebase.com>
@ -11856,6 +11845,19 @@ moonscale.net
// Submitted by Hannu Aronsson <haa@iki.fi>
iki.fi
// Individual Network Berlin e.V. : https://www.in-berlin.de/
// Submitted by Christian Seitz <chris@in-berlin.de>
dyn-berlin.de
in-berlin.de
in-brb.de
in-butter.de
in-dsl.de
in-dsl.net
in-dsl.org
in-vpn.de
in-vpn.net
in-vpn.org
// info.at : http://www.info.at/
biz.at
info.at
@ -11948,6 +11950,16 @@ leadpages.co
lpages.co
lpusercontent.com
// Lifetime Hosting : https://Lifetime.Hosting/
// Submitted by Mike Fillator <support@lifetime.hosting>
co.business
co.education
co.events
co.financial
co.network
co.place
co.technology
// Lightmaker Property Manager, Inc. : https://app.lmpm.com/
// Submitted by Greg Holland <greg.holland@lmpm.com>
app.lmpm.com
@ -12502,6 +12514,10 @@ spacekit.io
// Submitted by Stefan Neufeind <info@speedpartner.de>
customer.speedpartner.de
// Standard Library : https://stdlib.com
// Submitted by Jacob Lee <jacob@stdlib.com>
api.stdlib.com
// Storj Labs Inc. : https://storj.io/
// Submitted by Philip Hutchins <hostmaster@storj.io>
storj.farm
@ -12514,6 +12530,11 @@ utwente.io
// Submitted by Dan Miller <dm@sub6.com>
temp-dns.com
// Swisscom Application Cloud: https://developer.swisscom.com
// Submitted by Matthias.Winzeler <matthias.winzeler@swisscom.com>
applicationcloud.io
scapp.io
// Synology, Inc. : https://www.synology.com/
// Submitted by Rony Weng <ronyweng@synology.com>
diskstation.me
@ -12707,6 +12728,10 @@ za.org
// Submitted by Olli Vanhoja <olli@zeit.co>
now.sh
// Zine EOOD : https://zine.bg/
// Submitted by Martin Angelov <martin@zine.bg>
bss.design
// Zone.id : https://zone.id/
// Submitted by Su Hendro <admin@zone.id>
zone.id

View File

@ -638,22 +638,6 @@ static const StaticFingerprints kPinset_swehackCom = {
kPinset_swehackCom_Data
};
static const char* const kPinset_ncsccs_Data[] = {
kCOMODO_ECC_Certification_AuthorityFingerprint,
kDigiCert_Assured_ID_Root_CAFingerprint,
kDigiCert_High_Assurance_EV_Root_CAFingerprint,
kBaltimore_CyberTrust_RootFingerprint,
kLet_s_Encrypt_Authority_X3Fingerprint,
kCOMODO_RSA_Certification_AuthorityFingerprint,
kAddTrust_External_RootFingerprint,
kDigiCert_Global_Root_CAFingerprint,
kLet_s_Encrypt_Authority_X4Fingerprint,
};
static const StaticFingerprints kPinset_ncsccs = {
sizeof(kPinset_ncsccs_Data) / sizeof(const char*),
kPinset_ncsccs_Data
};
static const char* const kPinset_tumblr_Data[] = {
kDigiCert_High_Assurance_EV_Root_CAFingerprint,
kTumblrBackupFingerprint,
@ -677,7 +661,6 @@ struct TransportSecurityPreload {
/* Sort hostnames for binary search. */
static const TransportSecurityPreload kPublicKeyPinningPreloadList[] = {
{ "0.me.uk", true, false, false, -1, &kPinset_ncsccs },
{ "2mdn.net", true, false, false, -1, &kPinset_google_root_pems },
{ "accounts.firefox.com", true, false, true, 4, &kPinset_mozilla_services },
{ "accounts.google.com", true, false, false, -1, &kPinset_google_root_pems },
@ -1058,7 +1041,6 @@ static const TransportSecurityPreload kPublicKeyPinningPreloadList[] = {
{ "mx.search.yahoo.com", false, true, false, -1, &kPinset_yahoo },
{ "myaccount.google.com", true, false, false, -1, &kPinset_google_root_pems },
{ "myactivity.google.com", true, false, false, -1, &kPinset_google_root_pems },
{ "ncsccs.com", true, false, false, -1, &kPinset_ncsccs },
{ "ni.search.yahoo.com", false, true, false, -1, &kPinset_yahoo },
{ "nl.search.yahoo.com", false, true, false, -1, &kPinset_yahoo },
{ "no.search.yahoo.com", false, true, false, -1, &kPinset_yahoo },
@ -1095,7 +1077,6 @@ static const TransportSecurityPreload kPublicKeyPinningPreloadList[] = {
{ "security.google.com", true, false, false, -1, &kPinset_google_root_pems },
{ "services.mozilla.com", true, false, true, 6, &kPinset_mozilla_services },
{ "sg.search.yahoo.com", false, true, false, -1, &kPinset_yahoo },
{ "sirburton.com", true, false, false, -1, &kPinset_ncsccs },
{ "sites.google.com", true, false, false, -1, &kPinset_google_root_pems },
{ "spideroak.com", true, false, false, -1, &kPinset_spideroak },
{ "spreadsheets.google.com", true, false, false, -1, &kPinset_google_root_pems },
@ -1112,7 +1093,6 @@ static const TransportSecurityPreload kPublicKeyPinningPreloadList[] = {
{ "test-mode.pinning.example.com", true, true, false, -1, &kPinset_mozilla_test },
{ "testpilot.firefox.com", false, false, true, 9, &kPinset_mozilla_services },
{ "th.search.yahoo.com", false, true, false, -1, &kPinset_yahoo },
{ "themathematician.uk", true, false, false, -1, &kPinset_ncsccs },
{ "torproject.org", false, false, false, -1, &kPinset_tor },
{ "touch.facebook.com", true, false, false, -1, &kPinset_facebook },
{ "tr.search.yahoo.com", false, true, false, -1, &kPinset_yahoo },
@ -1166,8 +1146,8 @@ static const TransportSecurityPreload kPublicKeyPinningPreloadList[] = {
{ "zh.search.yahoo.com", false, true, false, -1, &kPinset_yahoo },
};
// Pinning Preload List Length = 487;
// Pinning Preload List Length = 483;
static const int32_t kUnknownId = -1;
static const PRTime kPreloadPKPinsExpirationTime = INT64_C(1556799343943000);
static const PRTime kPreloadPKPinsExpirationTime = INT64_C(1560428652618000);

File diff suppressed because it is too large Load Diff

View File

@ -4540,9 +4540,12 @@ XRE_InitCommandLine(int aArgc, char* aArgv[])
#endif
const char *path = nullptr;
ArgResult ar = CheckArg("greomni", false, &path);
ArgResult ar = CheckArg("greomni", true, &path);
if (ar == ARG_BAD) {
PR_fprintf(PR_STDERR, "Error: argument --greomni requires a path argument\n");
PR_fprintf(PR_STDERR,
"Error: argument --greomni requires a path argument or the "
"--osint argument was specified with the --appomni argument "
"which is invalid\n");
return NS_ERROR_FAILURE;
}
@ -4556,9 +4559,12 @@ XRE_InitCommandLine(int aArgc, char* aArgv[])
return rv;
}
ar = CheckArg("appomni", false, &path);
ar = CheckArg("appomni", true, &path);
if (ar == ARG_BAD) {
PR_fprintf(PR_STDERR, "Error: argument --appomni requires a path argument\n");
PR_fprintf(PR_STDERR,
"Error: argument --appomni requires a path argument or the "
"--osint argument was specified with the --appomni argument "
"which is invalid\n");
return NS_ERROR_FAILURE;
}

View File

@ -22,6 +22,7 @@
#include "nsIClassInfoImpl.h"
#include "mozilla/Attributes.h"
#include "mozilla/ipc/InputStreamUtils.h"
#include "mozilla/ReentrantMonitor.h"
#include "nsIIPCSerializableInputStream.h"
using namespace mozilla::ipc;
@ -47,13 +48,13 @@ public:
NS_DECL_NSIIPCSERIALIZABLEINPUTSTREAM
NS_DECL_NSICLONEABLEINPUTSTREAM
nsStringInputStream()
nsStringInputStream() : mMon("nsStringInputStream")
{
Clear();
}
explicit nsStringInputStream(const nsStringInputStream& aOther)
: mOffset(aOther.mOffset)
: mOffset(aOther.mOffset), mMon("nsStringInputStream")
{
// Use Assign() here because we don't want the life of the clone to be
// dependent on the life of the original stream.
@ -87,6 +88,8 @@ private:
nsDependentCSubstring mData;
uint32_t mOffset;
ReentrantMonitor mMon;
};
// This class needs to support threadsafe refcounting since people often
@ -124,6 +127,8 @@ nsStringInputStream::GetType(uint16_t* aType)
NS_IMETHODIMP
nsStringInputStream::GetData(nsACString& data)
{
ReentrantMonitorAutoEnter lock(mMon);
// The stream doesn't have any data when it is closed. We could fake it
// and return an empty string here, but it seems better to keep this return
// value consistent with the behavior of the other 'getter' methods.
@ -138,6 +143,8 @@ nsStringInputStream::GetData(nsACString& data)
NS_IMETHODIMP
nsStringInputStream::SetData(const nsACString& aData)
{
ReentrantMonitorAutoEnter lock(mMon);
mData.Assign(aData);
mOffset = 0;
return NS_OK;
@ -157,6 +164,8 @@ nsStringInputStream::ToString(char** aResult)
NS_IMETHODIMP
nsStringInputStream::SetData(const char* aData, int32_t aDataLen)
{
ReentrantMonitorAutoEnter lock(mMon);
if (NS_WARN_IF(!aData)) {
return NS_ERROR_INVALID_ARG;
}
@ -168,6 +177,8 @@ nsStringInputStream::SetData(const char* aData, int32_t aDataLen)
NS_IMETHODIMP
nsStringInputStream::AdoptData(char* aData, int32_t aDataLen)
{
ReentrantMonitorAutoEnter lock(mMon);
if (NS_WARN_IF(!aData)) {
return NS_ERROR_INVALID_ARG;
}
@ -179,6 +190,8 @@ nsStringInputStream::AdoptData(char* aData, int32_t aDataLen)
NS_IMETHODIMP
nsStringInputStream::ShareData(const char* aData, int32_t aDataLen)
{
ReentrantMonitorAutoEnter lock(mMon);
if (NS_WARN_IF(!aData)) {
return NS_ERROR_INVALID_ARG;
}
@ -199,6 +212,8 @@ nsStringInputStream::ShareData(const char* aData, int32_t aDataLen)
NS_IMETHODIMP
nsStringInputStream::Close()
{
ReentrantMonitorAutoEnter lock(mMon);
Clear();
return NS_OK;
}
@ -206,6 +221,8 @@ nsStringInputStream::Close()
NS_IMETHODIMP
nsStringInputStream::Available(uint64_t* aLength)
{
ReentrantMonitorAutoEnter lock(mMon);
NS_ASSERTION(aLength, "null ptr");
if (Closed()) {
@ -227,6 +244,8 @@ NS_IMETHODIMP
nsStringInputStream::ReadSegments(nsWriteSegmentFun aWriter, void* aClosure,
uint32_t aCount, uint32_t* aResult)
{
ReentrantMonitorAutoEnter lock(mMon);
NS_ASSERTION(aResult, "null ptr");
NS_ASSERTION(Length() >= mOffset, "bad stream state");
@ -270,6 +289,8 @@ nsStringInputStream::IsNonBlocking(bool* aNonBlocking)
NS_IMETHODIMP
nsStringInputStream::Seek(int32_t aWhence, int64_t aOffset)
{
ReentrantMonitorAutoEnter lock(mMon);
if (Closed()) {
return NS_BASE_STREAM_CLOSED;
}
@ -302,6 +323,8 @@ nsStringInputStream::Seek(int32_t aWhence, int64_t aOffset)
NS_IMETHODIMP
nsStringInputStream::Tell(int64_t* aOutWhere)
{
ReentrantMonitorAutoEnter lock(mMon);
if (Closed()) {
return NS_BASE_STREAM_CLOSED;
}
@ -313,6 +336,8 @@ nsStringInputStream::Tell(int64_t* aOutWhere)
NS_IMETHODIMP
nsStringInputStream::SetEOF()
{
ReentrantMonitorAutoEnter lock(mMon);
if (Closed()) {
return NS_BASE_STREAM_CLOSED;
}
@ -329,6 +354,8 @@ void
nsStringInputStream::Serialize(InputStreamParams& aParams,
FileDescriptorArray& /* aFDs */)
{
ReentrantMonitorAutoEnter lock(mMon);
StringInputStreamParams params;
params.data() = PromiseFlatCString(mData);
aParams = params;
@ -368,6 +395,8 @@ nsStringInputStream::GetCloneable(bool* aCloneableOut)
NS_IMETHODIMP
nsStringInputStream::Clone(nsIInputStream** aCloneOut)
{
ReentrantMonitorAutoEnter lock(mMon);
RefPtr<nsIInputStream> ref = new nsStringInputStream(*this);
ref.forget(aCloneOut);
return NS_OK;