Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1)

Side by Side Diff: chrome/common/extensions/extension_file_util.h

Issue 6297003: Fail gracefully if profile Temp dir can not be accessed. (Closed) Base URL: http://git.chromium.org/git/chromium.git
Patch Set: Address rev comments. Created 9 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/common/chrome_paths.cc ('k') | chrome/common/extensions/extension_file_util.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_COMMON_EXTENSIONS_EXTENSION_FILE_UTIL_H_ 5 #ifndef CHROME_COMMON_EXTENSIONS_EXTENSION_FILE_UTIL_H_
6 #define CHROME_COMMON_EXTENSIONS_EXTENSION_FILE_UTIL_H_ 6 #define CHROME_COMMON_EXTENSIONS_EXTENSION_FILE_UTIL_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 #include <map> 10 #include <map>
11 11
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 // We need to reserve the namespace of entries that start with "_" for future 69 // We need to reserve the namespace of entries that start with "_" for future
70 // use by Chrome. 70 // use by Chrome.
71 // If any files or directories are found using "_" prefix and are not on 71 // If any files or directories are found using "_" prefix and are not on
72 // reserved list we return false, and set error message. 72 // reserved list we return false, and set error message.
73 bool CheckForIllegalFilenames(const FilePath& extension_path, 73 bool CheckForIllegalFilenames(const FilePath& extension_path,
74 std::string* error); 74 std::string* error);
75 75
76 // Get a relative file path from a chrome-extension:// URL. 76 // Get a relative file path from a chrome-extension:// URL.
77 FilePath ExtensionURLToRelativeFilePath(const GURL& url); 77 FilePath ExtensionURLToRelativeFilePath(const GURL& url);
78 78
79 // Get a path to a temp directory for unpacking an extension.
80 // This is essentially PathService::Get(chrome::DIR_USER_DATA_TEMP, ...),
81 // with a histogram that allows us to understand why it is failing.
82 // Return an empty file path on failure.
83 FilePath GetUserDataTempDir();
84
79 } // namespace extension_file_util 85 } // namespace extension_file_util
80 86
81 #endif // CHROME_COMMON_EXTENSIONS_EXTENSION_FILE_UTIL_H_ 87 #endif // CHROME_COMMON_EXTENSIONS_EXTENSION_FILE_UTIL_H_
OLDNEW
« no previous file with comments | « chrome/common/chrome_paths.cc ('k') | chrome/common/extensions/extension_file_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698