I don't have active any script add-in that does anything when closing a Lister, or when exiting DO.
Windows registry is not modified to automatically close programs on reboot and the timeout is not modified.
It seems to be something DO related to the way it saves some configuration. I have tried changing some DO preferences (changes in prefs.osd are not written immediately either), after rebooting I can see that the changes made are present. If it's something from Windows on my system, it should also affect it in that sense right?
Do you see the same issue if you use FIle > Exit Directory Opus instead of rebooting?
To Opus, the shutdown should be the same. Main difference is Windows won't impose a time limit if it takes a long time.
Checking how long it takes for dopus.exe to be removed from the Task Manager / Processes tab should also tell us if shutdown is taking an abnormally long time.
(Unless the issue only happens when other things are shutting down at the same time, which is always possible. The machine will be under more load, and a component that loads itself into multiple processes or needs to talk to its main process that's now shutdown may go wrong, perhaps. I've also heard of one issue, many years ago, where one of the antivirus tools would throw away filesystem changes that happened after a certain point during shutdown, as another possibility.)
No, only when rebooting /shutdown. And it seems that only affects some of the configuration. (e.g. all the config stored in prefs.osd is written properly in any scenario).
Also, there's no Windows warning on reboot/shutdown when an app is taking too long to close.
That makes me think it's more related to DO than Windows. Perhaps if more people following the steps I have described above, can check if the FAYT command history is saved after a reboot it may shed more light on the issue.
I found that a few things (including FAYT history) were being saved quite late in the shutdown process, and have moved them to earlier in the sequence.
This means they're now saved while still processing the shutdown message from Windows, which should hopefully mean they get saved before Windows kills the process.