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

Unified Diff: runtime/bin/directory_macos.cc

Issue 61633003: Fix large-file support for mac os x. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 1 month 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
« no previous file with comments | « no previous file | runtime/bin/file_macos.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/directory_macos.cc
diff --git a/runtime/bin/directory_macos.cc b/runtime/bin/directory_macos.cc
index c5d307b9ba07468e01643086ab6c5fab4f07c0f5..feb9a9ca8dec1a7045eaac9bef0a6badd322c3e2 100644
--- a/runtime/bin/directory_macos.cc
+++ b/runtime/bin/directory_macos.cc
@@ -129,10 +129,10 @@ ListType DirectoryListingEntry::Next(DirectoryListing* listing) {
// readdir_r. For those and for links we use stat to determine
// the actual entry type. Notice that stat returns the type of
// the file pointed to.
- struct stat64 entry_info;
+ struct stat entry_info;
int stat_success;
stat_success = TEMP_FAILURE_RETRY(
- lstat64(listing->path_buffer().AsString(), &entry_info));
+ lstat(listing->path_buffer().AsString(), &entry_info));
if (stat_success == -1) {
return kListError;
}
@@ -151,7 +151,7 @@ ListType DirectoryListingEntry::Next(DirectoryListing* listing) {
previous = previous->next;
}
stat_success = TEMP_FAILURE_RETRY(
- stat64(listing->path_buffer().AsString(), &entry_info));
+ stat(listing->path_buffer().AsString(), &entry_info));
if (stat_success == -1) {
// Report a broken link as a link, even if follow_links is true.
return kListLink;
@@ -230,8 +230,8 @@ static bool DeleteDir(char* dir_name,
static bool DeleteRecursively(PathBuffer* path) {
// Do not recurse into links for deletion. Instead delete the link.
// If it's a file, delete it.
- struct stat64 st;
- if (TEMP_FAILURE_RETRY(lstat64(path->AsString(), &st)) == -1) {
+ struct stat st;
+ if (TEMP_FAILURE_RETRY(lstat(path->AsString(), &st)) == -1) {
return false;
} else if (S_ISREG(st.st_mode) || S_ISLNK(st.st_mode)) {
return (unlink(path->AsString()) == 0);
@@ -276,13 +276,13 @@ static bool DeleteRecursively(PathBuffer* path) {
// On some file systems the entry type is not determined by
// readdir_r. For those we use lstat to determine the entry
// type.
- struct stat64 entry_info;
+ struct stat entry_info;
if (!path->Add(entry.d_name)) {
success = false;
break;
}
int lstat_success = TEMP_FAILURE_RETRY(
- lstat64(path->AsString(), &entry_info));
+ lstat(path->AsString(), &entry_info));
if (lstat_success == -1) {
success = false;
break;
@@ -314,8 +314,8 @@ static bool DeleteRecursively(PathBuffer* path) {
Directory::ExistsResult Directory::Exists(const char* dir_name) {
- struct stat64 entry_info;
- int success = TEMP_FAILURE_RETRY(stat64(dir_name, &entry_info));
+ struct stat entry_info;
+ int success = TEMP_FAILURE_RETRY(stat(dir_name, &entry_info));
if (success == 0) {
if (S_ISDIR(entry_info.st_mode)) {
return EXISTS;
« no previous file with comments | « no previous file | runtime/bin/file_macos.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698