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

Unified Diff: ppapi/thunk/ppb_video_capture_thunk.cc

Issue 9113044: Convert to new enter method (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: PATCH DESCRIPTIONS ARE A STUPID WASTE OF TIME Created 8 years, 11 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 | « ppapi/thunk/ppb_url_loader_thunk.cc ('k') | ppapi/thunk/ppb_video_decoder_thunk.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/thunk/ppb_video_capture_thunk.cc
diff --git a/ppapi/thunk/ppb_video_capture_thunk.cc b/ppapi/thunk/ppb_video_capture_thunk.cc
index fbd1f2b7d4b4c9c51436115482324595e939ae4f..d677471d2288ab3fd91a1a97a34d9aaff8c3fac0 100644
--- a/ppapi/thunk/ppb_video_capture_thunk.cc
+++ b/ppapi/thunk/ppb_video_capture_thunk.cc
@@ -3,7 +3,6 @@
// found in the LICENSE file.
#include "ppapi/c/pp_errors.h"
-#include "ppapi/thunk/common.h"
#include "ppapi/thunk/enter.h"
#include "ppapi/thunk/thunk.h"
#include "ppapi/thunk/ppb_video_capture_api.h"
@@ -33,8 +32,7 @@ int32_t StartCapture(PP_Resource video_capture,
uint32_t buffer_count) {
EnterVideoCapture enter(video_capture, true);
if (enter.failed())
- return PP_ERROR_BADRESOURCE;
-
+ return enter.retval();
return enter.object()->StartCapture(*requested_info, buffer_count);
}
@@ -42,16 +40,14 @@ int32_t ReuseBuffer(PP_Resource video_capture,
uint32_t buffer) {
EnterVideoCapture enter(video_capture, true);
if (enter.failed())
- return PP_ERROR_BADRESOURCE;
-
+ return enter.retval();
return enter.object()->ReuseBuffer(buffer);
}
int32_t StopCapture(PP_Resource video_capture) {
EnterVideoCapture enter(video_capture, true);
if (enter.failed())
- return PP_ERROR_BADRESOURCE;
-
+ return enter.retval();
return enter.object()->StopCapture();
}
« no previous file with comments | « ppapi/thunk/ppb_url_loader_thunk.cc ('k') | ppapi/thunk/ppb_video_decoder_thunk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698