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

Unified Diff: webkit/glue/plugins/plugin_data_stream.cc

Issue 2896: This CB fixes the following issues:-... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 12 years, 3 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
« no previous file with comments | « webkit/glue/plugins/plugin_data_stream.h ('k') | webkit/glue/plugins/plugin_host.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/glue/plugins/plugin_data_stream.cc
===================================================================
--- webkit/glue/plugins/plugin_data_stream.cc (revision 2387)
+++ webkit/glue/plugins/plugin_data_stream.cc (working copy)
@@ -1,46 +0,0 @@
-// Copyright (c) 2006-2008 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.
-
-#include "webkit/glue/plugins/plugin_data_stream.h"
-
-#include "base/logging.h"
-
-namespace NPAPI {
-
-PluginDataStream::PluginDataStream(PluginInstance *instance,
- const std::string& url,
- const std::string& mime_type,
- const std::string& headers,
- uint32 expected_length,
- uint32 last_modified)
- : PluginStream(instance, url.c_str(), false, 0),
- mime_type_(mime_type),
- headers_(headers),
- expected_length_(expected_length),
- last_modified_(last_modified),
- stream_open_failed_(false) {
-}
-
-PluginDataStream::~PluginDataStream() {
-}
-
-void PluginDataStream::SendToPlugin(const char* buffer, int length) {
- if (stream_open_failed_)
- return;
-
- if (!open()) {
- if (!Open(mime_type_, headers_, expected_length_, last_modified_)) {
- stream_open_failed_ = true;
- return;
- }
- }
-
- // TODO(iyengar) - check if it was not fully sent, and figure out a
- // backup plan.
- int written = Write(buffer, length);
- DCHECK(written == length);
-}
-
-} // namespace NPAPI
-
« no previous file with comments | « webkit/glue/plugins/plugin_data_stream.h ('k') | webkit/glue/plugins/plugin_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698