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

Unified Diff: content/browser/appcache/appcache_response.cc

Issue 1154283003: Change most uses of Pickle to base::Pickle (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 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: content/browser/appcache/appcache_response.cc
diff --git a/content/browser/appcache/appcache_response.cc b/content/browser/appcache/appcache_response.cc
index 0c0f4bf1e3ec3daeb05932d4044789c2be242f3d..66ec22ec81b31ef959967fccfac098ad648f74b9 100644
--- a/content/browser/appcache/appcache_response.cc
+++ b/content/browser/appcache/appcache_response.cc
@@ -29,16 +29,16 @@ enum { kResponseInfoIndex, kResponseContentIndex, kResponseMetadataIndex };
// pickle is transfered to the WrappedPickleIOBuffer object.
class WrappedPickleIOBuffer : public net::WrappedIOBuffer {
public:
- explicit WrappedPickleIOBuffer(const Pickle* pickle) :
- net::WrappedIOBuffer(reinterpret_cast<const char*>(pickle->data())),
- pickle_(pickle) {
+ explicit WrappedPickleIOBuffer(const base::Pickle* pickle)
+ : net::WrappedIOBuffer(reinterpret_cast<const char*>(pickle->data())),
+ pickle_(pickle) {
DCHECK(pickle->data());
}
private:
~WrappedPickleIOBuffer() override {}
- scoped_ptr<const Pickle> pickle_;
+ scoped_ptr<const base::Pickle> pickle_;
};
} // anon namespace
@@ -254,7 +254,7 @@ void AppCacheResponseReader::OnIOComplete(int result) {
reading_metadata_size_ = 0;
} else if (info_buffer_.get()) {
// Deserialize the http info structure, ensuring we got headers.
- Pickle pickle(buffer_->data(), result);
+ base::Pickle pickle(buffer_->data(), result);
scoped_ptr<net::HttpResponseInfo> info(new net::HttpResponseInfo);
bool response_truncated = false;
if (!info->InitFromPickle(pickle, &response_truncated) ||
@@ -336,7 +336,7 @@ void AppCacheResponseWriter::ContinueWriteInfo() {
const bool kSkipTransientHeaders = true;
const bool kTruncated = false;
- Pickle* pickle = new Pickle;
+ base::Pickle* pickle = new base::Pickle;
info_buffer_->http_info->Persist(pickle, kSkipTransientHeaders, kTruncated);
write_amount_ = static_cast<int>(pickle->size());
buffer_ = new WrappedPickleIOBuffer(pickle); // takes ownership of pickle

Powered by Google App Engine
This is Rietveld 408576698