Index: components/autofill/core/common/password_form.h |
diff --git a/components/autofill/core/common/password_form.h b/components/autofill/core/common/password_form.h |
index 5c7bee5db561a034d0a6d768881804f9c622e5ef..189f929ef972f29420ac43729486efed4aed04bc 100644 |
--- a/components/autofill/core/common/password_form.h |
+++ b/components/autofill/core/common/password_form.h |
@@ -9,6 +9,8 @@ |
#include <string> |
#include <vector> |
+#include "base/containers/scoped_ptr_map.h" |
+#include "base/memory/scoped_ptr.h" |
#include "base/time/time.h" |
#include "components/autofill/core/common/form_data.h" |
#include "url/gurl.h" |
@@ -280,8 +282,10 @@ struct PasswordForm { |
}; |
// Map username to PasswordForm* for convenience. See password_form_manager.h. |
-typedef std::map<base::string16, PasswordForm*> PasswordFormMap; |
+typedef base::ScopedPtrMap<base::string16, scoped_ptr<PasswordForm>> |
+ PasswordFormMap; |
+// Like PasswordFormMap, but with weak (not owned) pointers. |
typedef std::map<base::string16, const PasswordForm*> ConstPasswordFormMap; |
// For testing. |