Index: components/password_manager/content/browser/bad_message.h |
diff --git a/chrome/browser/bad_message.h b/components/password_manager/content/browser/bad_message.h |
similarity index 66% |
copy from chrome/browser/bad_message.h |
copy to components/password_manager/content/browser/bad_message.h |
index 36026851192532bb710730ec60fa05c22f945af3..ed1be504cad5d62be71ad02de8c309725fcad6c3 100644 |
--- a/chrome/browser/bad_message.h |
+++ b/components/password_manager/content/browser/bad_message.h |
@@ -2,14 +2,14 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
-#ifndef CHROME_BROWSER_BAD_MESSAGE_H_ |
-#define CHROME_BROWSER_BAD_MESSAGE_H_ |
+#ifndef COMPONENTS_PASSWORD_MANAGER_CONTENT_BROWSER_BAD_MESSAGE_H_ |
+#define COMPONENTS_PASSWORD_MANAGER_CONTENT_BROWSER_BAD_MESSAGE_H_ |
namespace content { |
-class BrowserMessageFilter; |
class RenderProcessHost; |
} |
+namespace password_manager { |
namespace bad_message { |
// The browser process often chooses to terminate a renderer if it receives |
@@ -23,11 +23,11 @@ namespace bad_message { |
// running: |
// python tools/metrics/histograms/update_bad_message_reasons.py |
enum BadMessageReason { |
- WRLHH_LOGGING_STOPPED_BAD_STATE = 0, |
+ CPMD_BAD_ORIGIN = 0, |
// Please add new elements here. The naming convention is abbreviated class |
- // name (e.g. RenderFrameHost becomes RFH) plus a unique description of the |
- // reason. |
+ // name (e.g. ContentPasswordManagerDriver becomes CPMD) plus a unique |
+ // description of the reason. |
BAD_MESSAGE_MAX |
}; |
@@ -37,12 +37,7 @@ enum BadMessageReason { |
void ReceivedBadMessage(content::RenderProcessHost* host, |
BadMessageReason reason); |
-// Called when a browser message filter receives a bad IPC message from a |
-// renderer or other child process. Logs the event, records a histogram metric |
-// for the |reason|, and terminates the process for |filter|. |
-void ReceivedBadMessage(content::BrowserMessageFilter* filter, |
- BadMessageReason reason); |
- |
} // namespace bad_message |
+} // namespace password_manager |
-#endif // CHROME_BROWSER_BAD_MESSAGE_H_ |
+#endif // COMPONENTS_PASSWORD_MANAGER_CONTENT_BROWSER_BAD_MESSAGE_H_ |