Fix normalization of error message about unique violation when creating intermediate dirs. Thanks to Tim Sampson for the report.