I am using RegisterWaitForSingleObject to watch a directory for changes. I only need to be notified of the first change so I am passing WT_EXECUTEONLYONCE. Everything is fine so far.
My question is: do I still need to cancel the wait operation in this case with either UnRegisterWait or UnRegisterWaitEx or is that done automatically once the operation signals or times out?
Yep, you need to dispose of the handle;