RxCreateNetFobx function (fcb.h)

RxCreateNetFobx allocates, initializes, and inserts a new file object extension (FOBX) structure into the in-memory data structures for a FCB that this FOBX is being opened on.

Syntax

PMRX_FOBX RxCreateNetFobx(
  [out] OUT PRX_CONTEXT  RxContext,
  [in]  IN PMRX_SRV_OPEN MrxSrvOpen
);

Parameters

[out] RxContext

A pointer to the RX_CONTEXT structure describing a create operation.

[in] MrxSrvOpen

A pointer to the associated SRV_OPEN structure.

Return value

RxCreateNetFobx returns a pointer to a newly allocated FOBX data structure on success or a NULL pointer on failure.

Remarks

Network mini-redirectors should call RxCreateNetFobx to create an FOBX at the end of a successful create operation.

Before calling RxCreateNetFobx, the FCB associated with the FOBX structure must be acquired in exclusive mode.

RxCreateNetFobx will try and use the FOBX allocated as part of the associated FCB structure if it is available. If the FOBX allocated with the FCB is not available, then RxCreateNetFobx will try and use the FOBX allocated as part of the associated SRV_OPEN structure if it is available. In either of these cases, RxCreateNetFobx only needs to initialize the existing FOBX structure, no memory allocation is required. If both of the FOBX structures on the associated FCB and SRV_OPEN structure are not available, then RxCreateNetFobx will allocate a new FOBX structure.

If the associated FCB is a paging file, RxCreateNetFobx allocates non-paged pool memory when creating the new FOBX data structure. If the associated FCB is a not a paging file, RxCreateNetFobx allocates paged pool memory when creating the new FOBX data structure.

Windows does not currently allow having a paging file on a remote machine.

On success, the following FOBX members in the FOBX structure are set:

  • The NodeReference member is set to 1.
  • The FobxSerialNumber member is set to 0.
  • The SrvOpen member is set to the associated SRV_OPEN structure.
  • The fOpenCountDecremented member is set to FALSE.
  • The Flags member is set to a value based on parameters from the RX_CONTEXT and whether a new FOBX needed to be allocated.
On success, the reference count for the SRV_OPEN structure is incremented and the NumberOfFobxs member on the associated V_NET_ROOT structure is incremented.

Requirements

Requirement Value
Target Platform Desktop
Header fcb.h (include Rxcontx.h, Mrxfcb.h, Fcb.h)
IRQL <= APC_LEVEL

See also

RX_CONTEXT

RxCreateNetFcb

RxCreateNetRoot

RxCreateSrvCall

RxCreateSrvOpen

RxCreateVNetRoot

RxDereference

RxFinalizeConnection

RxFinalizeNetFcb

RxFinalizeNetFobx

RxFinalizeNetRoot

RxFinalizeSrvCall

RxFinalizeSrvOpen

RxFinalizeVNetRoot

RxFinishFcbInitialization

RxForceFinalizeAllVNetRoots

RxReference

RxSetSrvCallDomainName

RxpDereferenceNetFcb

RxpReferenceNetFcb