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

Unified Diff: ppapi/proxy/ppb_video_capture_proxy.cc

Issue 9595004: Coverity: Fix several pass-by-values. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 10 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 | « no previous file | ppapi/shared_impl/ppb_video_capture_shared.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/proxy/ppb_video_capture_proxy.cc
diff --git a/ppapi/proxy/ppb_video_capture_proxy.cc b/ppapi/proxy/ppb_video_capture_proxy.cc
index 8477d530b74e595c3b5991f694e69582b63ff37c..6a51299bd66b82fc34087769d4858201e059dff9 100644
--- a/ppapi/proxy/ppb_video_capture_proxy.cc
+++ b/ppapi/proxy/ppb_video_capture_proxy.cc
@@ -164,12 +164,12 @@ class VideoCapture : public PPB_VideoCapture_Shared {
// PPB_VideoCapture_Shared implementation.
virtual int32_t InternalEnumerateDevices(
PP_Resource* devices,
- PP_CompletionCallback callback) OVERRIDE;
+ const PP_CompletionCallback& callback) OVERRIDE;
virtual int32_t InternalOpen(
const std::string& device_id,
const PP_VideoCaptureDeviceInfo_Dev& requested_info,
uint32_t buffer_count,
- PP_CompletionCallback callback) OVERRIDE;
+ const PP_CompletionCallback& callback) OVERRIDE;
virtual int32_t InternalStartCapture() OVERRIDE;
virtual int32_t InternalReuseBuffer(uint32_t buffer) OVERRIDE;
virtual int32_t InternalStopCapture() OVERRIDE;
@@ -213,8 +213,8 @@ bool VideoCapture::OnStatus(PP_VideoCaptureStatus_Dev status) {
return false;
}
-int32_t VideoCapture::InternalEnumerateDevices(PP_Resource* devices,
- PP_CompletionCallback callback) {
+int32_t VideoCapture::InternalEnumerateDevices(
+ PP_Resource* devices, const PP_CompletionCallback& callback) {
devices_ = devices;
enumerate_devices_callback_ = new TrackedCallback(this, callback);
GetDispatcher()->Send(new PpapiHostMsg_PPBVideoCapture_EnumerateDevices(
@@ -226,7 +226,7 @@ int32_t VideoCapture::InternalOpen(
const std::string& device_id,
const PP_VideoCaptureDeviceInfo_Dev& requested_info,
uint32_t buffer_count,
- PP_CompletionCallback callback) {
+ const PP_CompletionCallback& callback) {
// Disallow blocking call. The base class doesn't check this.
if (!callback.func)
return PP_ERROR_BLOCKS_MAIN_THREAD;
« no previous file with comments | « no previous file | ppapi/shared_impl/ppb_video_capture_shared.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698