summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--dom/base/nsContentPolicyUtils.h2
-rw-r--r--extensions/permissions/nsContentBlocker.cpp9
2 files changed, 9 insertions, 2 deletions
diff --git a/dom/base/nsContentPolicyUtils.h b/dom/base/nsContentPolicyUtils.h
index 3cef7923e..600b24c56 100644
--- a/dom/base/nsContentPolicyUtils.h
+++ b/dom/base/nsContentPolicyUtils.h
@@ -115,7 +115,6 @@ NS_CP_ContentTypeName(uint32_t contentType)
CASE_RETURN( TYPE_FETCH );
CASE_RETURN( TYPE_IMAGESET );
CASE_RETURN( TYPE_WEB_MANIFEST );
- CASE_RETURN( TYPE_SAVEAS_DOWNLOAD );
CASE_RETURN( TYPE_INTERNAL_SCRIPT );
CASE_RETURN( TYPE_INTERNAL_WORKER );
CASE_RETURN( TYPE_INTERNAL_SHARED_WORKER );
@@ -135,6 +134,7 @@ NS_CP_ContentTypeName(uint32_t contentType)
CASE_RETURN( TYPE_INTERNAL_IMAGE_FAVICON );
CASE_RETURN( TYPE_INTERNAL_STYLESHEET );
CASE_RETURN( TYPE_INTERNAL_STYLESHEET_PRELOAD );
+ CASE_RETURN( TYPE_SAVEAS_DOWNLOAD );
default:
return "<Unknown Type>";
}
diff --git a/extensions/permissions/nsContentBlocker.cpp b/extensions/permissions/nsContentBlocker.cpp
index 278ec21a0..391785dc3 100644
--- a/extensions/permissions/nsContentBlocker.cpp
+++ b/extensions/permissions/nsContentBlocker.cpp
@@ -23,6 +23,7 @@
#define BEHAVIOR_NOFOREIGN 3
// From nsIContentPolicy
+// and nsIContentPolicyBase.idl: Their order must be retained!
static const char *kTypeString[] = {
"other",
"script",
@@ -46,7 +47,6 @@ static const char *kTypeString[] = {
"fetch",
"image",
"manifest",
- "saveas_download",
"", // TYPE_INTERNAL_SCRIPT
"", // TYPE_INTERNAL_WORKER
"", // TYPE_INTERNAL_SHARED_WORKER
@@ -60,6 +60,13 @@ static const char *kTypeString[] = {
"", // TYPE_INTERNAL_XMLHTTPREQUEST
"", // TYPE_INTERNAL_EVENTSOURCE
"", // TYPE_INTERNAL_SERVICE_WORKER
+ "", // TYPE_INTERNAL_SCRIPT_PRELOAD
+ "", // TYPE_INTERNAL_IMAGE
+ "", // TYPE_INTERNAL_IMAGE_PRELOAD
+ "", // TYPE_INTERNAL_STYLESHEET
+ "", // TYPE_INTERNAL_STYLESHEET_PRELOAD
+ "", // TYPE_INTERNAL_IMAGE_FAVICON
+ "saveas_download",
};
#define NUMBER_OF_TYPES MOZ_ARRAY_LENGTH(kTypeString)