Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Overly conservative result from FSEventsGetLastEventIdForDeviceBeforeTime()



Hi,

I'm calling FSEventsGetLastEventIdForDeviceBeforeTime() to get the sinceWhen event id for a new file system events stream.

My problem is that the value returned is very small and I'm getting really old events. For example, the time I passed in for my latest test was about 10 minutes ago (NSDate=2008-03-27 11:42:40). The starting ID returned by FSEventsGetLastEventIdForDeviceBeforeTime() was 147,036. Using that value to create the event stream delivers events that are weeks, even months, old. The latest event number on this device is 13,037,960.

I was worried that I might have the time base wrong. But FSEventsGetLastEventIdForDeviceBeforeTime says it takes a CFAbsoluteTime, which is the number of seconds since 1/1/2001. I'm passing in an -[NSDate timeIntervalSinceReferenceDate] which should also be the number of seconds since 1/1/2001.

In fact, I just went back and tested it a couple of more times and no matter what date I pass it, it returns 147,036.

Am I missing something?

--
James Bucanek

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Filesystem-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/filesystem-dev/email@hidden

This email sent to email@hidden


Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.