I have just closed
#1450: Problems handling non-existent directories.
In the end, only a few changes were made. However, all the code is complex, so problems may remain.
Please test the mkdirs branch and report any problems immediately. I plan to merge mkdirs into devel in the next say or so.
Edward