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

Unified Diff: chrome/browser/chromeos/fileapi/external_file_url_request_job.cc

Issue 1036723003: favor DCHECK_CURRENTLY_ON for better logs in chrome/browser/chromeos/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 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: chrome/browser/chromeos/fileapi/external_file_url_request_job.cc
diff --git a/chrome/browser/chromeos/fileapi/external_file_url_request_job.cc b/chrome/browser/chromeos/fileapi/external_file_url_request_job.cc
index 972f68dc27c0e21c8d719600d0a2ef132b69a20e..ca8aea8f4dcae07971b4d315c1cd49525b194554 100644
--- a/chrome/browser/chromeos/fileapi/external_file_url_request_job.cc
+++ b/chrome/browser/chromeos/fileapi/external_file_url_request_job.cc
@@ -241,7 +241,7 @@ void ExternalFileURLRequestJob::OnHelperResultObtained(
void ExternalFileURLRequestJob::OnRedirectURLObtained(
const GURL& redirect_url) {
- DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
+ DCHECK_CURRENTLY_ON(BrowserThread::IO);
redirect_url_ = redirect_url;
if (!redirect_url_.is_empty()) {
NotifyHeadersComplete();
@@ -258,7 +258,7 @@ void ExternalFileURLRequestJob::OnRedirectURLObtained(
void ExternalFileURLRequestJob::OnFileInfoObtained(
base::File::Error result,
const base::File::Info& file_info) {
- DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
+ DCHECK_CURRENTLY_ON(BrowserThread::IO);
if (result == base::File::FILE_ERROR_NOT_FOUND) {
NotifyStartError(net::URLRequestStatus(net::URLRequestStatus::FAILED,
@@ -298,7 +298,7 @@ void ExternalFileURLRequestJob::OnFileInfoObtained(
}
void ExternalFileURLRequestJob::Kill() {
- DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
+ DCHECK_CURRENTLY_ON(BrowserThread::IO);
stream_reader_.reset();
isolated_file_system_scope_.reset();
@@ -308,14 +308,14 @@ void ExternalFileURLRequestJob::Kill() {
}
bool ExternalFileURLRequestJob::GetMimeType(std::string* mime_type) const {
- DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
+ DCHECK_CURRENTLY_ON(BrowserThread::IO);
mime_type->assign(mime_type_);
return !mime_type->empty();
}
bool ExternalFileURLRequestJob::IsRedirectResponse(GURL* location,
int* http_status_code) {
- DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
+ DCHECK_CURRENTLY_ON(BrowserThread::IO);
if (redirect_url_.is_empty())
return false;
@@ -329,7 +329,7 @@ bool ExternalFileURLRequestJob::IsRedirectResponse(GURL* location,
bool ExternalFileURLRequestJob::ReadRawData(net::IOBuffer* buf,
int buf_size,
int* bytes_read) {
- DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
+ DCHECK_CURRENTLY_ON(BrowserThread::IO);
DCHECK(stream_reader_);
if (remaining_bytes_ == 0) {
@@ -364,7 +364,7 @@ ExternalFileURLRequestJob::~ExternalFileURLRequestJob() {
}
void ExternalFileURLRequestJob::OnReadCompleted(int read_result) {
- DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
+ DCHECK_CURRENTLY_ON(BrowserThread::IO);
if (read_result < 0) {
DCHECK_NE(read_result, net::ERR_IO_PENDING);
« no previous file with comments | « chrome/browser/chromeos/external_metrics.cc ('k') | chrome/browser/chromeos/login/chrome_restart_request.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698