For some reason on certain setups  appending  causign the routing to go wacky. This is a fix for that.
Data directory permission check