Last Comment Bug 783086 - [DeviceStorage]: in OOP apps, the enumerate() method ignores the since argument
: [DeviceStorage]: in OOP apps, the enumerate() method ignores the since argument
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: DOM: Device Interfaces (show other bugs)
: Trunk
: x86 Mac OS X
: -- normal (vote)
: mozilla17
Assigned To: Doug Turner (:dougt)
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-08-15 13:54 PDT by David Flanagan [:djf]
Modified: 2012-08-17 05:26 PDT (History)
4 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
patch v.1 (1.83 KB, patch)
2012-08-15 15:04 PDT, Doug Turner (:dougt)
khuey: review-
Details | Diff | Splinter Review
patch v.1 (3.28 KB, patch)
2012-08-16 15:18 PDT, Doug Turner (:dougt)
dhylands: review+
Details | Diff | Splinter Review

Description David Flanagan [:djf] 2012-08-15 13:54:14 PDT
The gallery app just switched to OOP, which triggered a DeviceStorage bug:

My call to enumerate() ignores the since property of the options object.  It returns files with mod times before the specified date.  Blacklisting the app again makes the bug go away.

I'd guess that you're serializing the options object to go cross process but the Date object isn't serializing correctly.

If you want to change the API to take a timestamp instead of a Date object it is probably not too late to do that.  Otherwise, you'll have to manually serialize the date.

I've seen this on desktop and on otoro
Comment 1 Doug Turner (:dougt) 2012-08-15 15:04:34 PDT
Created attachment 652251 [details] [diff] [review]
patch v.1
Comment 2 Kyle Huey [:khuey] (Exited; not receiving bugmail, email if necessary) 2012-08-16 15:16:48 PDT
Comment on attachment 652251 [details] [diff] [review]
patch v.1

Wrong patch.
Comment 3 Doug Turner (:dougt) 2012-08-16 15:18:40 PDT
Created attachment 652587 [details] [diff] [review]
patch v.1
Comment 4 Doug Turner (:dougt) 2012-08-16 15:19:19 PDT
Comment on attachment 652587 [details] [diff] [review]
patch v.1

ingore the printf()
Comment 5 Dave Hylands [:dhylands] 2012-08-16 16:07:49 PDT
Comment on attachment 652587 [details] [diff] [review]
patch v.1

Review of attachment 652587 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good (ignoring the printf in nsDeviceStorage.cpp)
Comment 7 Ed Morley [:emorley] 2012-08-17 05:26:54 PDT
https://hg.mozilla.org/mozilla-central/rev/431d680e9e2f

Note You need to log in before you can comment on or make changes to this bug.