Create the extensions (<Profile>/Extensions) and user script (<Profile>/User Scripts) directories during start up if they don't already exists
Review URL: http://codereview.chromium.org/29001
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10134 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/chrome/browser/extensions/extensions_service.cc b/chrome/browser/extensions/extensions_service.cc
index c469c086b..13d43a5 100644
--- a/chrome/browser/extensions/extensions_service.cc
+++ b/chrome/browser/extensions/extensions_service.cc
@@ -162,6 +162,11 @@
const FilePath& path_in,
scoped_refptr<ExtensionsServiceFrontendInterface> frontend) {
FilePath path = path_in;
+
+ // Create the <Profile>/Extensions directory if it doesn't exist.
+ if (!file_util::DirectoryExists(path))
+ file_util::CreateDirectory(path);
+
if (!file_util::AbsolutePath(&path))
NOTREACHED();