Bug 1358227 - Removed the MOZ_ALLOW_WEAKER_SANDBOX environment variable; r?jimm
The Flash sandbox (which is the only thing this variable is used for) is stable
at this point, and for testing purposes we still have MOZ_DISABLE_NPAPI_SANDBOX.
MozReview-Commit-ID: 6sxb1tx7oA9
--- a/dom/plugins/base/nsPluginTags.cpp
+++ b/dom/plugins/base/nsPluginTags.cpp
@@ -430,20 +430,19 @@ nsPluginTag::InitSandboxLevel()
sandboxPref.Append(GetNiceFileName());
if (NS_FAILED(Preferences::GetInt(sandboxPref.get(), &mSandboxLevel))) {
mSandboxLevel = Preferences::GetInt("dom.ipc.plugins.sandbox-level.default"
);
}
#if defined(_AMD64_)
// As level 2 is now the default NPAPI sandbox level for 64-bit flash, we
- // don't want to allow a lower setting unless this environment variable is
- // set. This should be changed if the firefox.js pref file is changed.
- if (mIsFlashPlugin &&
- !PR_GetEnv("MOZ_ALLOW_WEAKER_SANDBOX") && mSandboxLevel < 2) {
+ // don't want to allow a lower setting. This should be changed if the
+ // firefox.js pref file is changed.
+ if (mIsFlashPlugin && mSandboxLevel < 2) {
mSandboxLevel = 2;
}
#endif
#endif
}
#if !defined(XP_WIN) && !defined(XP_MACOSX)
static nsresult ConvertToUTF8(nsIUnicodeDecoder *aUnicodeDecoder,
@@ -482,17 +481,17 @@ nsresult nsPluginTag::EnsureMembersAreUT
nsAutoCString charset;
rv = pcs->GetCharset(kPlatformCharsetSel_FileName, charset);
NS_ENSURE_SUCCESS(rv, rv);
if (!charset.LowerCaseEqualsLiteral("utf-8")) {
decoder = EncodingUtils::DecoderForEncoding(charset);
ConvertToUTF8(decoder, mFileName);
ConvertToUTF8(decoder, mFullPath);
}
-
+
// The description of the plug-in and the various MIME type descriptions
// should be encoded in the standard plain text file encoding for this system.
// XXX should we add kPlatformCharsetSel_PluginResource?
rv = pcs->GetCharset(kPlatformCharsetSel_PlainTextInFile, charset);
NS_ENSURE_SUCCESS(rv, rv);
if (!charset.LowerCaseEqualsLiteral("utf-8")) {
decoder = EncodingUtils::DecoderForEncoding(charset);
ConvertToUTF8(decoder, mName);