summaryrefslogtreecommitdiffstats
path: root/src/input/pvsprivinputd.cpp
diff options
context:
space:
mode:
authorSebastien Braun2010-10-06 15:09:43 +0200
committerSebastien Braun2010-10-06 15:09:43 +0200
commitc5c91f40c02d7b8611fb5e479f340fe19254592f (patch)
tree47384add2533c27506f673929c18af3726127f57 /src/input/pvsprivinputd.cpp
parentRefactor signal handling in pvsprivinputd (diff)
downloadpvs-c5c91f40c02d7b8611fb5e479f340fe19254592f.tar.gz
pvs-c5c91f40c02d7b8611fb5e479f340fe19254592f.tar.xz
pvs-c5c91f40c02d7b8611fb5e479f340fe19254592f.zip
Fix deletion order bug
PVSCheckPrivileges::instance() is statically allocated. When it is deleted, the QCoreApplication is already gone (since it is stack- allocated), and the destructor of QFileSystemWatcher waits forever.
Diffstat (limited to 'src/input/pvsprivinputd.cpp')
-rw-r--r--src/input/pvsprivinputd.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/input/pvsprivinputd.cpp b/src/input/pvsprivinputd.cpp
index 361bf9f..2f19d90 100644
--- a/src/input/pvsprivinputd.cpp
+++ b/src/input/pvsprivinputd.cpp
@@ -28,6 +28,7 @@
#include <QCoreApplication>
#include <QStringList>
#include <QSocketNotifier>
+#include "pvsCheckPrivileges.h"
#include "pvsPrivInputSocket.h"
#include "pvsPrivInputHandler.h"
#include "pvsPrivInputSignalHandler.h"
@@ -151,5 +152,7 @@ int main(int argc, char** argv)
// and run the main loop.
int ret = app.exec();
+
+ PVSCheckPrivileges::deleteInstance();
return ret;
}