From b2c22bf846d5259ca35c5f4824f05d459590aad7 Mon Sep 17 00:00:00 2001 From: unknown Date: Mon, 22 Aug 2011 06:42:28 -0400 Subject: [PATCH] update comments --- src/cpp/core/system/file_monitor/FileMonitor.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/cpp/core/system/file_monitor/FileMonitor.cpp b/src/cpp/core/system/file_monitor/FileMonitor.cpp index ff8a5194deb..7e4d9d21a19 100644 --- a/src/cpp/core/system/file_monitor/FileMonitor.cpp +++ b/src/cpp/core/system/file_monitor/FileMonitor.cpp @@ -17,8 +17,6 @@ // QueueUserAPC and SetWaitableTimer // or perhaps just a standard sleep call with event coalescing would do it -// TODO: consider wrapping the entire thread within an object lifetime - // TODO: safety feature for unregistration -- ignore requets with a non-active // Handle (to prevent bad pointer deref). Note this is related to the final // item below on the correct abstraction level of the interface. @@ -27,6 +25,9 @@ // TODO: implement non-recursive mode +// TODO: consider returning parent iterator from function that does scan +// for existing file items (so we don't keep having to re-scan from the top + // TODO: see if there are filesystems/scenarios where filemon won't work // (we know remote SAMBA filesystems on windows won't for sure -- do // we get an error in this case or do notifications just not come) @@ -296,7 +297,7 @@ void unregisterMonitor(Handle handle); // for termination state on the monitor thread void stop(); -} // namespace impl +} // namespace detail namespace { @@ -367,7 +368,9 @@ CallbackQueue& callbackQueue() } -// track active handles so we can implement unregisterAll +// track active handles so we can implement unregisterAll. note that this +// list is accessed from the platform-specific file-monitor thread +// (checkForInput and catch clause of fileMonitorMainThread std::list s_activeHandles; void checkForInput()