ZwSetInformationTransaction function (wdm.h)

The ZwSetInformationTransaction routine sets information for a specified transaction.

Syntax

NTSYSCALLAPI NTSTATUS ZwSetInformationTransaction(
  [in] HANDLE                        TransactionHandle,
  [in] TRANSACTION_INFORMATION_CLASS TransactionInformationClass,
  [in] PVOID                         TransactionInformation,
  [in] ULONG                         TransactionInformationLength
);

Parameters

[in] TransactionHandle

A handle to a transaction object that was obtained by a previous call to ZwCreateTransaction or ZwOpenTransaction. The handle must have TRANSACTION_SET_INFORMATION access to the object.

[in] TransactionInformationClass

A TRANSACTION_INFORMATION_CLASS-typed value that specifies the type of information to set. The value must be TransactionPropertiesInformation.

[in] TransactionInformation

A pointer to a caller-allocated buffer that contains the information to set. The buffer's structure type must be TRANSACTION_PROPERTIES_INFORMATION.

[in] TransactionInformationLength

The length, in bytes, of the buffer that the TransactionInformation parameter points to.

Return value

ZwSetInformationTransaction returns STATUS_SUCCESS if the operation succeeds. Otherwise, this routine might return one of the following values:

Return code Description
STATUS_INVALID_INFO_CLASS
The TransactionInformationClass parameter's value is invalid.
STATUS_OBJECT_TYPE_MISMATCH
The handle that the TransactionHandle parameter specifies is not a handle to a transaction object.
STATUS_INVALID_HANDLE
An object handle is invalid.
STATUS_ACCESS_DENIED
The caller does not have appropriate access to the transaction object.
STATUS_INFO_LENGTH_MISMATCH
The TransactionInformationLength parameter's value is invalid.
STATUS_INVALID_PARAMETER
The contents of the buffer that the TransactionInformation buffer specifies is invalid.
 

The routine might return other NTSTATUS values.

Remarks

For more information about ZwSetInformationTransaction, see Creating a Transactional Client.

NtSetInformationTransaction and ZwSetInformationTransaction are two versions of the same Windows Native System Services routine.

For calls from kernel-mode drivers, the NtXxx and ZwXxx versions of a Windows Native System Services routine can behave differently in the way that they handle and interpret input parameters. For more information about the relationship between the NtXxx and ZwXxx versions of a routine, see Using Nt and Zw Versions of the Native System Services Routines.

Requirements

Requirement Value
Minimum supported client Available in Windows Vista and later operating system versions.
Target Platform Universal
Header wdm.h (include Wdm.h, Ntddk.h, Ntifs.h)
Library NtosKrnl.lib
DLL NtosKrnl.exe
IRQL PASSIVE_LEVEL
DDI compliance rules HwStorPortProhibitedDDIs(storport), PowerIrpDDis(wdm)

See also

TRANSACTION_INFORMATION_CLASS

TRANSACTION_PROPERTIES_INFORMATION

Using Nt and Zw Versions of the Native System Services Routines

ZwCreateTransaction

ZwOpenTransaction

ZwQueryInformationTransaction