From 3399d79773fcd57dded2a184ee94936469538b4b Mon Sep 17 00:00:00 2001 From: Thiago Macieira Date: Fri, 29 Sep 2017 21:20:08 -0700 Subject: QLockFile/Unix: drop the use of fcntl(F_SETLK) F_SETLK is bad. Explanation in the comment. And flock(2) does work with NFS on Linux, so let's just stick to that, which is simpler. We only use the file locks when we attempt to delete an apparently stale lock: that is, for a lock file that is at least staleLockTime old. Change-Id: I0b48fc8e90304e0dacc3fffd14e908c8c4c9d59b Reviewed-by: Oswald Buddenhagen Reviewed-by: David Faure --- src/corelib/io/qlockfile_p.h | 4 ---- 1 file changed, 4 deletions(-) (limited to 'src/corelib/io/qlockfile_p.h') diff --git a/src/corelib/io/qlockfile_p.h b/src/corelib/io/qlockfile_p.h index 86a606ec00..a6f61b20f3 100644 --- a/src/corelib/io/qlockfile_p.h +++ b/src/corelib/io/qlockfile_p.h @@ -85,10 +85,6 @@ public: // used in dbusmenu Q_CORE_EXPORT static QString processNameByPid(qint64 pid); -#ifdef Q_OS_UNIX - static int checkFcntlWorksAfterFlock(const QString &fn); -#endif - QString fileName; #ifdef Q_OS_WIN Qt::HANDLE fileHandle; -- cgit v1.2.3