summaryrefslogtreecommitdiffhomepage
path: root/facetracknoir/ui.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'facetracknoir/ui.cpp')
-rw-r--r--facetracknoir/ui.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/facetracknoir/ui.cpp b/facetracknoir/ui.cpp
index 8142e20a..5d3bc591 100644
--- a/facetracknoir/ui.cpp
+++ b/facetracknoir/ui.cpp
@@ -122,11 +122,14 @@ void MainWindow::save_mappings() {
#endif
void MainWindow::save() {
+ const QString currentFile = group::ini_pathname();
+ // Qt5 refuses writing to empty file
+ (void) QFile::remove(currentFile);
+
b->save();
save_mappings();
#if defined(__unix) || defined(__linux)
- const QString currentFile = group::ini_pathname();
QByteArray bytes = QFile::encodeName(currentFile);
const char* filename_as_asciiz = bytes.constData();