aboutsummaryrefslogtreecommitdiff
path: root/src/3rdParty/efsw/FileWatcherImpl.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/3rdParty/efsw/FileWatcherImpl.cpp')
-rwxr-xr-xsrc/3rdParty/efsw/FileWatcherImpl.cpp23
1 files changed, 23 insertions, 0 deletions
diff --git a/src/3rdParty/efsw/FileWatcherImpl.cpp b/src/3rdParty/efsw/FileWatcherImpl.cpp
new file mode 100755
index 0000000..f6b86a5
--- /dev/null
+++ b/src/3rdParty/efsw/FileWatcherImpl.cpp
@@ -0,0 +1,23 @@
1#include <efsw/FileWatcherImpl.hpp>
2#include <efsw/String.hpp>
3#include <efsw/System.hpp>
4
5namespace efsw {
6
7FileWatcherImpl::FileWatcherImpl( FileWatcher* parent ) :
8 mFileWatcher( parent ), mInitOK( false ), mIsGeneric( false ) {
9 System::maxFD();
10}
11
12FileWatcherImpl::~FileWatcherImpl() {}
13
14bool FileWatcherImpl::initOK() {
15 return static_cast<bool>( mInitOK );
16}
17
18bool FileWatcherImpl::linkAllowed( const std::string& curPath, const std::string& link ) {
19 return ( mFileWatcher->followSymlinks() && mFileWatcher->allowOutOfScopeLinks() ) ||
20 -1 != String::strStartsWith( curPath, link );
21}
22
23} // namespace efsw