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

Unified Diff: webkit/glue/plugins/webplugin_delegate_impl.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/webplugin_delegate_impl.h ('k') | webkit/glue/webplugin.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/glue/plugins/webplugin_delegate_impl.cc
===================================================================
--- webkit/glue/plugins/webplugin_delegate_impl.cc (revision 2387)
+++ webkit/glue/plugins/webplugin_delegate_impl.cc (working copy)
@@ -1002,7 +1002,18 @@
WebPluginResourceClient* WebPluginDelegateImpl::CreateResourceClient(
int resource_id, const std::string &url, bool notify_needed,
- void *notify_data) {
+ void *notify_data, void* existing_stream) {
+ // Stream already exists. This typically happens for range requests
+ // initiated via NPN_RequestRead.
+ if (existing_stream) {
+ NPAPI::PluginStream* plugin_stream =
+ reinterpret_cast<NPAPI::PluginStream*>(existing_stream);
+
+ plugin_stream->CancelRequest();
+
+ return plugin_stream->AsResourceClient();
+ }
+
if (notify_needed) {
instance()->SetURLLoadData(GURL(url.c_str()), notify_data);
}
« no previous file with comments | « webkit/glue/plugins/webplugin_delegate_impl.h ('k') | webkit/glue/webplugin.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698