diff options
author | evan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-01-29 23:42:05 +0000 |
---|---|---|
committer | evan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-01-29 23:42:05 +0000 |
commit | 78202defa5a10cf23c768f6b0013cb1365051a3d (patch) | |
tree | 57ae95b30b4be34381d14229050e2f9963ac8c28 /webkit/glue | |
parent | e5c833013915ba6d19d8426993bfa21b6c1d3018 (diff) | |
download | chromium_src-78202defa5a10cf23c768f6b0013cb1365051a3d.zip chromium_src-78202defa5a10cf23c768f6b0013cb1365051a3d.tar.gz chromium_src-78202defa5a10cf23c768f6b0013cb1365051a3d.tar.bz2 |
Add a comment on the quick fix I just did.
Review URL: http://codereview.chromium.org/548209
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@37564 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/glue')
-rw-r--r-- | webkit/glue/webplugin_impl.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/webkit/glue/webplugin_impl.cc b/webkit/glue/webplugin_impl.cc index 296b65de..ceb4239 100644 --- a/webkit/glue/webplugin_impl.cc +++ b/webkit/glue/webplugin_impl.cc @@ -353,6 +353,11 @@ void WebPluginImpl::didFailLoading(const WebURLError& error) { void WebPluginImpl::didFinishLoadingFrameRequest( const WebURL& url, void* notify_data) { if (delegate_) { + // We're converting a void* into an arbitrary int id. Though + // these types are the same size on all the platforms we support, + // the compiler may complain as though they are different, so to + // make the casting gods happy go through an intptr_t (the union + // of void* and int) rather than converting straight across. delegate_->DidFinishLoadWithReason( url, NPRES_DONE, reinterpret_cast<intptr_t>(notify_data)); } @@ -365,6 +370,7 @@ void WebPluginImpl::didFailLoadingFrameRequest( NPReason reason = error.reason == net::ERR_ABORTED ? NPRES_USER_BREAK : NPRES_NETWORK_ERR; + // See comment in didFinishLoadingFrameRequest about the cast here. delegate_->DidFinishLoadWithReason( url, reason, reinterpret_cast<intptr_t>(notify_data)); } |