2.1.5.11.1 Waiting for Change Notification to be Reported
Wait until the following conditions are satisfied:
There are one or more elements in ChangeNotifyEntry.NotifyEventList.
This change notification request is the oldest outstanding request on this Open. This means multiple change notification requests on the same Open are completed sequentially and in first-in-first-out (FIFO) order.
The operation is canceled as specified in section 2.1.5.20.
Pseudocode for the operation is as follows:
When a ChangeNotifyEntry.NotifyEventList element is available:
If all entries from ChangeNotifyEntry.NotifyEventList fit in OutputBufferSize bytes:
Remove all NotifyEventEntries from ChangeNotifyEntry.NotifyEventList.
Copy NotifyEventEntries to OutputBuffer.
Set Status to STATUS_SUCCESS.
Set ByteCount to the size of OutputBuffer, in bytes.
Else:
Set Status to STATUS_NOTIFY_ENUM_DIR.
Set ByteCount to zero.
EndIf
EndIf