Hi @Hangkun Ung ,
The timeout alone does not establish that the provider connection has been lost. Since other folders still work, I would first investigate the affected directory’s population state and the cleanup of its outstanding enumeration request.
To fail gracefully, I suggest completing the request explicitly before the platform timeout rather than letting it expire. Use CfExecute with CF_OPERATION_TYPE_TRANSFER_PLACEHOLDERS, supplying an appropriate failure NTSTATUS in TransferPlaceholders.CompletionStatus and the corresponding callback identifiers. Please also check and log the HRESULT returned by CfExecute to confirm that the completion was accepted.
For slow enumerations, you can transfer available placeholders in batches instead of waiting for the entire listing. Microsoft documents a 60-second callback timeout, but valid CfExecute calls reset pending callback timers for the same provider process. Note that the timeout-reset behavior documented for CfReportProviderProgress specifically concerns FETCH_DATA, so I would not assume it applies to FETCH_PLACEHOLDERS.
For the missing callbacks after timeout, please check:
- Whether any completion path sets
CF_OPERATION_TRANSFER_PLACEHOLDERS_FLAG_DISABLE_ON_DEMAND_POPULATIONprematurely. That flag prevents subsequentFETCH_PLACEHOLDERScallbacks and should indicate that the directory is fully populated. - Whether timeout or cancellation leaves an outstanding task, lock, or “enumeration in progress” entry in your engine. Log callback entry before any application-side filtering to distinguish callbacks that never arrive from callbacks your engine ignores.
Could you share the Windows version/build, the FETCH_PLACEHOLDERS handler and its failure/cancellation paths, and the last CfExecute arguments and return value? Also, does “restart everything” mean restarting Explorer, reconnecting the provider, restarting the provider process, or rebooting Windows?
Hope these information help. If you found my response helpful or informative, I would greatly appreciate it if you could follow this guide for your confirmation.
Thank you.