Closed Bug 1505962 Opened 2 years ago Closed 2 years ago
Add redirection for rand()
While in a single threaded context we should be able to control for the random number seed and generate the same sequence of numbers, there are several ways in which we could fail to replay the numbers exactly --- if rand() is called while events are passed through, or if it is called from multiple threads whose accesses aren't synchronized. The attached patch adds a redirection to ensure that rand() calls always produce the same value.
Attachment #9023802 - Flags: review?(lsmyth)
Attachment #9023802 - Flags: review?(lsmyth) → review+
Pushed by firstname.lastname@example.org: https://hg.mozilla.org/integration/mozilla-inbound/rev/fa47f2e5c1fb Add redirection for rand(), r=lsmyth.
This patch broke Web Replay on 10.13 (and possibly other versions), backing out for now. https://hg.mozilla.org/integration/mozilla-inbound/rev/c418b8e31eacc847c27c03c4636ce3315c0c7e2f
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Pushed by email@example.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/f3cea0fce1e0 Add redirection for rand(), r=lsmyth.
It turns out this patch never broke things after all (after backing it out 10.13 was still broken), but the problem was with the CGColorSpaceCreateDeviceGray redirection added by bug 1505922.
Status: REOPENED → RESOLVED
Closed: 2 years ago → 2 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.