ULONG PeripheralNumber,
PKEY_VALUE_FULL_INFORMATION* PI);
-typedef NTSTATUS STDCALL_FUNC
+typedef NTSTATUS
+#ifndef LIBCAPTIVE
+ STDCALL_FUNC
+#else /* !LIBCAPTIVE */
+ CAPTIVE_STDCALL
+#endif /* !LIBCAPTIVE */
(*PIO_COMPLETION_ROUTINE)(struct _DEVICE_OBJECT* DeviceObject,
struct _IRP* Irp,
PVOID Context);
/*
* Driver cancel declaration
*/
-typedef NTSTATUS STDCALL_FUNC
+typedef NTSTATUS
+#ifndef LIBCAPTIVE
+ STDCALL_FUNC
+#else /* !LIBCAPTIVE */
+ CAPTIVE_STDCALL
+#endif /* !LIBCAPTIVE */
(*PDRIVER_CANCEL)(struct _DEVICE_OBJECT* DeviceObject,
struct _IRP* RegistryPath);
(!NT_SUCCESS(Irp->IoStatus.Status) && (Irp->Stack[i].Control & SL_INVOKE_ON_ERROR)) ||
(Irp->Cancel && (Irp->Stack[i].Control & SL_INVOKE_ON_CANCEL))))
{
+#ifndef LIBCAPTIVE
Status = Irp->Stack[i].CompletionRoutine(DeviceObject,
Irp,
Irp->Stack[i].Context);
+#else /* !LIBCAPTIVE */
+ Status = (NTSTATUS)captive_stdcall_call_12((CaptiveStdCallFunc12)Irp->Stack[i].CompletionRoutine,
+ DeviceObject,
+ Irp,
+ Irp->Stack[i].Context);
+#endif /* LIBCAPTIVE */
if (Status == STATUS_MORE_PROCESSING_REQUIRED)
{