Lion seem to have more events, so just truncate to SL range for now.

This commit is contained in:
Maxim Shafirov
2011-07-26 15:18:06 +04:00
parent 4b253e3b38
commit fbb231abbc
2 changed files with 3 additions and 2 deletions
Binary file not shown.
+3 -2
View File
@@ -109,7 +109,8 @@ void callback(ConstFSEventStreamRef streamRef,
int i;
for (i=0; i<numEvents; i++) {
FSEventStreamEventFlags flags = eventFlags[i];
// TODO Lion has much more detailed flags we need accurately process. For now just reduce to SL events range
FSEventStreamEventFlags flags = eventFlags[i] & 0xFF;
if (flags == kFSEventStreamEventFlagMount || flags == kFSEventStreamEventFlagUnmount) {
ReportMountedFileSystems();
}
@@ -117,7 +118,7 @@ void callback(ConstFSEventStreamRef streamRef,
printf("RECDIRTY\n");
printf("%s\n", paths[i]);
}
else if (eventFlags[i] != kFSEventStreamEventFlagNone) {
else if (flags != kFSEventStreamEventFlagNone) {
printf("RESET\n");
}
else {