Fix memory leaks when a renderer crashes and the user refreshes.  Also fix memory leak every time a renderer process goes away.

Review URL: http://codereview.chromium.org/115492

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16415 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/chrome/browser/child_process_security_policy.h b/chrome/browser/child_process_security_policy.h
index 9b675cf..ae1eb41 100644
--- a/chrome/browser/child_process_security_policy.h
+++ b/chrome/browser/child_process_security_policy.h
@@ -13,6 +13,7 @@
 #include "base/file_path.h"
 #include "base/lock.h"
 #include "base/singleton.h"
+#include "testing/gtest/include/gtest/gtest_prod.h"
 
 class FilePath;
 class GURL;
@@ -93,6 +94,9 @@
   bool HasDOMUIBindings(int renderer_id);
 
  private:
+  friend class ChildProcessSecurityPolicyInProcessBrowserTest;
+  FRIEND_TEST(ChildProcessSecurityPolicyInProcessBrowserTest, NoLeak);
+
   class SecurityState;
 
   typedef std::set<std::string> SchemeSet;