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

Side by Side Diff: ppapi/native_client/tests/ppapi_browser/crash/ppapi_crash_in_callback.cc

Issue 7740013: Cloning a bunch of stuff from the native_client repository at r6528 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2011 The Native Client Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "native_client/src/shared/platform/nacl_check.h"
6 #include "ppapi/c/pp_errors.h"
7 #include "ppapi/c/ppb_core.h"
8 #include "native_client/tests/ppapi_test_lib/get_browser_interface.h"
9 #include "native_client/tests/ppapi_test_lib/test_interface.h"
10
11
12 namespace {
13
14 void CrashingCallback(void* /*user_data*/, int32_t /*result*/) {
15 printf("--- CrashingCallback\n");
16 CRASH;
17 }
18
19 void CrashInCallback() {
20 printf("--- CrashInCallback\n");
21 PP_CompletionCallback callback =
22 PP_MakeCompletionCallback(CrashingCallback, NULL);
23 PPBCore()->CallOnMainThread(0 /*delay*/, callback, PP_OK);
24 }
25
26 } // namespace
27
28 void SetupTests() {
29 RegisterTest("CrashInCallback", CrashInCallback);
30 }
31
32 void SetupPluginInterfaces() {
33 // none
34 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698