Index: ppapi/c/private/ppb_nacl_private.h |
diff --git a/ppapi/c/private/ppb_nacl_private.h b/ppapi/c/private/ppb_nacl_private.h |
index e275a909bdb3ac6bdaaae63ca805bd63bf505a58..939f37f4d45ac16e0ef31094214b0e319c3f4599 100644 |
--- a/ppapi/c/private/ppb_nacl_private.h |
+++ b/ppapi/c/private/ppb_nacl_private.h |
@@ -1,4 +1,4 @@ |
-// Copyright (c) 2011 The Chromium Authors. All rights reserved. |
+// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
@@ -8,7 +8,7 @@ |
#include "ppapi/c/pp_resource.h" |
#include "ppapi/c/pp_stdint.h" |
-#define PPB_NACL_PRIVATE_INTERFACE "PPB_NaCl(Private);0.2" |
+#define PPB_NACL_PRIVATE_INTERFACE "PPB_NaCl(Private);0.3" |
struct PPB_NaCl_Private { |
// This function launches NaCl's sel_ldr process. On success, the function |
@@ -33,6 +33,22 @@ struct PPB_NaCl_Private { |
// Enables the creation of sel_ldr processes from other than the main thread. |
void (*EnableBackgroundSelLdrLaunch)(); |
+ |
+ // This is Windows-specific. This is a replacement for |
+ // DuplicateHandle() for use inside the Windows sandbox. Note that |
+ // we provide this via dependency injection only to avoid the |
+ // linkage problems that occur because the NaCl plugin is built as a |
+ // separate DLL/DSO (see |
+ // http://code.google.com/p/chromium/issues/detail?id=114439#c8). |
+ // We use void* rather than the Windows HANDLE type to avoid an |
+ // #ifdef here. We use int rather than PP_Bool/bool so that this is |
+ // usable with NaClSetBrokerDuplicateHandleFunc() without further |
+ // wrapping. |
+ int (*BrokerDuplicateHandle)(void* source_handle, |
+ uint32_t process_id, |
+ void** target_handle, |
+ uint32_t desired_access, |
+ uint32_t options); |
}; |
#endif // PPAPI_C_PRIVATE_PPB_NACL_PRIVATE_H_ |