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

Unified Diff: content/browser/net/network_error_request_job.h

Issue 1421743002: Implement chrome://network-errors for direct access to network error interstitials (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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
Index: content/browser/net/network_error_request_job.h
diff --git a/content/browser/net/network_error_request_job.h b/content/browser/net/network_error_request_job.h
new file mode 100644
index 0000000000000000000000000000000000000000..cb2b3fdbc17861769448800f177e1372ab8faf45
--- /dev/null
+++ b/content/browser/net/network_error_request_job.h
@@ -0,0 +1,38 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CONTENT_BROWSER_NET_NETWORK_ERROR_REQUEST_JOB_H_
+#define CONTENT_BROWSER_NET_NETWORK_ERROR_REQUEST_JOB_H_
+
+#include <string>
+
+#include "base/macros.h"
+#include "net/url_request/url_request_simple_job.h"
+
+namespace content {
+class URLRequest;
+class NetworkDelegate;
+
+class NetworkErrorRequestJob : public net::URLRequestSimpleJob {
mmenke 2015/11/24 22:42:35 I think we can get rid of this class, and use URLR
edwardjung 2015/11/26 16:12:16 Done.
+ public:
+ NetworkErrorRequestJob(net::URLRequest* request,
+ net::NetworkDelegate* network_delegate);
+
+ int GetData(std::string* mime_type,
+ std::string* charset,
+ std::string* data,
+ const net::CompletionCallback& callback) const override;
+
+ private:
+ ~NetworkErrorRequestJob() override {}
+
+ // The error_code passed in via the path.
+ int error_code_;
+
+ DISALLOW_COPY_AND_ASSIGN(NetworkErrorRequestJob);
+};
+
+} // namespace content
+
+#endif // CONTENT_BROWSER_NET_NETWORK_ERROR_REQUEST_JOB_H_

Powered by Google App Engine
This is Rietveld 408576698