Skip to content
Snippets Groups Projects
Commit d048fbd1 authored by Langella Olivier's avatar Langella Olivier
Browse files

check directory permission

parent 4f482f87
No related branches found
No related tags found
No related merge requests found
......@@ -103,7 +103,11 @@ void EditTandemPresetDialog::doSelectDir() {
QString directory = QFileDialog::getExistingDirectory(this,tr("Choose preset directory"),_preset_directory );
QFileInfo my_dir(directory);
if (!directory.isEmpty() && ! directory.isNull()) {
if (!my_dir.isWritable()) {
throw pappso::PappsoException(QObject::tr("this directory is not writable, check permissions (%1)").arg(my_dir.absoluteFilePath()));
}
_preset_directory = directory;
fillPresetComboBox();
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment