Fix mode for log directory