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

Unified Diff: storage/browser/fileapi/file_system_operation_impl.cc

Issue 1498003003: Remove kint64max. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: INT64_MAX Created 5 years 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: storage/browser/fileapi/file_system_operation_impl.cc
diff --git a/storage/browser/fileapi/file_system_operation_impl.cc b/storage/browser/fileapi/file_system_operation_impl.cc
index b6a699778b920517e50c5798602195e8f55a0d33..7cc26c0064c61aedc8ef062835312a7882bc43e0 100644
--- a/storage/browser/fileapi/file_system_operation_impl.cc
+++ b/storage/browser/fileapi/file_system_operation_impl.cc
@@ -4,6 +4,8 @@
#include "storage/browser/fileapi/file_system_operation_impl.h"
+#include <limits>
+
#include "base/bind.h"
#include "base/single_thread_task_runner.h"
#include "base/strings/utf_string_conversions.h"
@@ -198,7 +200,8 @@ void FileSystemOperationImpl::Write(
weak_factory_.GetWeakPtr(), url, callback));
}
-void FileSystemOperationImpl::Truncate(const FileSystemURL& url, int64 length,
+void FileSystemOperationImpl::Truncate(const FileSystemURL& url,
+ int64_t length,
const StatusCallback& callback) {
DCHECK(SetPendingOperationType(kOperationTruncate));
@@ -393,7 +396,8 @@ void FileSystemOperationImpl::GetUsageAndQuotaThenRunTask(
!file_system_context()->GetQuotaUtil(url.type())) {
// If we don't have the quota manager or the requested filesystem type
// does not support quota, we should be able to let it go.
- operation_context_->set_allowed_bytes_growth(kint64max);
+ operation_context_->set_allowed_bytes_growth(
+ std::numeric_limits<int64_t>::max());
task.Run();
return;
}
@@ -411,8 +415,8 @@ void FileSystemOperationImpl::DidGetUsageAndQuotaAndRunTask(
const base::Closure& task,
const base::Closure& error_callback,
storage::QuotaStatusCode status,
- int64 usage,
- int64 quota) {
+ int64_t usage,
+ int64_t quota) {
if (status != storage::kQuotaStatusOk) {
LOG(WARNING) << "Got unexpected quota error : " << status;
error_callback.Run();
@@ -483,7 +487,7 @@ void FileSystemOperationImpl::DoCopyInForeignFile(
void FileSystemOperationImpl::DoTruncate(const FileSystemURL& url,
const StatusCallback& callback,
- int64 length) {
+ int64_t length) {
async_file_util_->Truncate(
operation_context_.Pass(), url, length,
base::Bind(&FileSystemOperationImpl::DidFinishOperation,
@@ -572,7 +576,7 @@ void FileSystemOperationImpl::DidWrite(
const FileSystemURL& url,
const WriteCallback& write_callback,
base::File::Error rv,
- int64 bytes,
+ int64_t bytes,
FileWriterDelegate::WriteProgressStatus write_status) {
const bool complete = (
write_status != FileWriterDelegate::SUCCESS_IO_PENDING);
« no previous file with comments | « storage/browser/fileapi/file_system_operation_impl.h ('k') | storage/browser/fileapi/sandbox_file_stream_writer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698