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

Unified Diff: base/file_util_posix.cc

Issue 12212010: Truncate the download file name if it exceeds the filesystem limit. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: GetVolumePathName(). Created 7 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: base/file_util_posix.cc
diff --git a/base/file_util_posix.cc b/base/file_util_posix.cc
index 5bf4fb10d31b7298db2e4c44b8ce87c40b863a9d..3f1edec541f16beb1136dcd11be58b90c0eaa150 100644
--- a/base/file_util_posix.cc
+++ b/base/file_util_posix.cc
@@ -1130,4 +1130,9 @@ bool VerifyPathControlledByAdmin(const FilePath& path) {
}
#endif // defined(OS_MACOSX) && !defined(OS_IOS)
+int GetMaximumPathComponentLength(const FilePath& path) {
+ base::ThreadRestrictions::AssertIOAllowed();
+ return pathconf(path.value().c_str(), _PC_NAME_MAX);
+}
+
} // namespace file_util
« no previous file with comments | « base/file_util.h ('k') | base/file_util_win.cc » ('j') | base/file_util_win.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698