mirror of
https://bitbucket.org/smil3y/kdelibs.git
synced 2025-02-24 02:42:48 +00:00
kdecore: check if file is already beeing watched to avoid stat and warning
Signed-off-by: Ivailo Monev <xakepa10@laimg.moc>
This commit is contained in:
parent
c2f8387fa6
commit
3cf1801b68
1 changed files with 2 additions and 0 deletions
|
@ -98,6 +98,8 @@ void KDirWatch::addFile(const QString& path)
|
|||
{
|
||||
if (path.isEmpty() || path.startsWith(QLatin1String("/dev"))) {
|
||||
return; // Don't even go there.
|
||||
} else if (d->watcher->files().contains(path)) {
|
||||
return;
|
||||
}
|
||||
|
||||
QFileInfo info(path);
|
||||
|
|
Loading…
Add table
Reference in a new issue