RtkOpenEvent
RtkOpenEvent returns a handle to an existing named RTSS event object.
Syntax
NTSTATUS RtkOpenEvent(
[in] RTSSINST RtssInst,
[out] PHANDLE EventHandle,
[ignored] ULONG DesiredAccess,
[ignored] BOOLEAN InheritHandle,
[in] PUNICODE_STRING Name
);
Parameters
[in] RtssInst
An RTSSINST value returned from a call to RtkRtssAttach or RtkRtssAttachEx. Pass a valid RTSSINST value or the call will fail with STATUS_INVALID_PARAMETER.
[out] EventHandle
A pointer to a handle that will receive a handle to the existing event object. Pass a valid pointer to a handle or the call will fail with STATUS_INVALID_PARAMETER.
[ignored] DesiredAccess
Ignored. The desired access to the event object.
[ignored] InheritHandle
If this value is TRUE, processes created by this process will inherit the handle. Otherwise, the processes do not inherit this handle.
[in] Name
A pointer to a PUNICODE_STRING specifying the name of the event object. The name is limited to 260 characters and can contain any character except the backslash path-separator character (\). Name comparison is case-sensitive.
Return Value
If the function succeeds, it returns STATUS_SUCCESS. If the function fails, it returns one of the following NTSTATUS error codes:
- STATUS_INVALID_PARAMETER
- STATUS_UNSUCCESSFUL
- STATUS_INVALID_HANDLE
- STATUS_NO_SUCH_DEVICE
Remarks
RtkOpenEvent enables multiple processes to open handles of the same event object. The function succeeds only if some process has already created the event with RtkCreateEvent. The calling process can use the returned handle in any function that requires a handle of an event object, such as a wait function.
Use RtkCloseHandle to close the handle. The system closes the handle automatically when the process terminates. The event object is destroyed when its last handle has been closed.
Requirements
| Minimum supported version | Header | Library |
IRQL |
|---|---|---|---|
|
wRTOS 1.0 SDK |
RtkApi.h |
RtkApi_W64.lib |
PASSIVE_LEVEL |
See Also: