diff options
author | Christian Kamm <mail@ckamm.de> | 2018-04-24 10:52:15 +0300 |
---|---|---|
committer | ckamm <mail@ckamm.de> | 2018-04-24 14:06:50 +0300 |
commit | 9555f8d75c90b8ec59323c30d23a0164f658ecf9 (patch) | |
tree | 62797db1061b078577bbada2ed3a1d7dfa23b412 /src/gui/folderwatcher_linux.cpp | |
parent | 073de7a8e0ba2a96737b63fe9f6b948517453cb6 (diff) |
Show a tray message when a folder watcher becomes unreliable #6119
Diffstat (limited to 'src/gui/folderwatcher_linux.cpp')
-rw-r--r-- | src/gui/folderwatcher_linux.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gui/folderwatcher_linux.cpp b/src/gui/folderwatcher_linux.cpp index 37d79211a..5f6d580b1 100644 --- a/src/gui/folderwatcher_linux.cpp +++ b/src/gui/folderwatcher_linux.cpp @@ -81,8 +81,11 @@ void FolderWatcherPrivate::inotifyRegisterPath(const QString &path) } else { // If we're running out of memory or inotify watches, become // unreliable. - if (errno == ENOMEM || errno == ENOSPC) { + if (_parent->_isReliable && (errno == ENOMEM || errno == ENOSPC)) { _parent->_isReliable = false; + emit _parent->becameUnreliable( + tr("This problem usually happens when the inotify watches are exhausted. " + "Check the FAQ for details.")); } } } |