[Qt-interest] QFileSystemWatcher on an NFS share
André Somers
andre at familiesomers.nl
Thu Feb 18 20:10:16 CET 2010
Interesting question.
I have run into the downsides in the pimpl too at times. One way would be to
patch Qt, and make the changes you need. If you manage to do that in a BC
way, you may even get the Trolls to accept the patch. Another way is to copy
the code out of Qt into your own code, or a separate library that you link
into your project.
André
Van: qt-interest-bounces at trolltech.com
[mailto:qt-interest-bounces at trolltech.com] Namens Tiemen Schut
Verzonden: donderdag 18 februari 2010 11:41
Aan: qt-interest at trolltech.com
Onderwerp: [Qt-interest] QFileSystemWatcher on an NFS share
Dear list,
Currently, I'm using QFileSystemWatcher to watch files for changes, as it is
intended to. This is all well for local files, but I don't get any
notifications for files on an NFS mount.
This makes sense, as the default implementation on Linux uses inotify if
available, and inotify doesn't support NFS shares. I've looked in the
sources for qfilesystemwatcher, and saw that there *is* support for a
polling engine (instead of inotify). However, there is no public interface
to force the use of the polling engine (or any other engine for that
matter).
I've thought about subclassing QFileSystemWatcher to force it to use the
polling engine. Unfortunately, that will not work because of pimpl. Maybe
there is a way to get this to work, but if there is, I wouldn't know how.
Any suggestions on how to get QFileSystemWatcher to be able to watch files
on an NFS share would be welcome!
Thanks,
Tiemen
P.S. This is with Qt 4.6.0 on linux.
--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20100218/4f287ee3/attachment.html
More information about the Qt-interest-old
mailing list