Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upMax session fix #15026
Max session fix #15026
Conversation
highfive
commented
Jan 14, 2017
|
Thanks for the pull request, and welcome! The Servo team is excited to review your changes, and you should hear from @jdm (or someone else) soon. |
highfive
commented
Jan 14, 2017
|
Heads up! This PR modifies the following files:
|
|
Let's squash all the commits into one, as well. |
| @@ -56,6 +56,7 @@ | |||
| "layout.viewport.enabled": false, | |||
| "layout.writing-mode.enabled": false, | |||
| "network.mime.sniff": false, | |||
| "session_history.max_length":20, | |||
This comment has been minimized.
This comment has been minimized.
jdm
Jan 14, 2017
Member
Let's use session-history.max-length to be consistent with other preference names. Also, add a space after :.
This comment has been minimized.
This comment has been minimized.
| @@ -2136,7 +2136,8 @@ impl<Message, LTF, STF> Constellation<Message, LTF, STF> | |||
| } else if let Some(frame) = self.frames.get_mut(&frame_change.frame_id) { | |||
| debug!("Adding pipeline to existing frame."); | |||
| frame.load(frame_change.new_pipeline_id, frame_change.url.clone()); | |||
| let evicted_id = frame.prev.len().checked_sub(opts::get().max_session_history) | |||
| let evicted_id = frame.prev.len() | |||
| .checked_sub(PREFS.get("session_history.max_length").as_u64().unwrap_or(20) as usize) | |||
This comment has been minimized.
This comment has been minimized.
|
@bors-servo: r+ |
|
|
Max session fix <!-- Please describe your changes on the following line: --> Converted document discarding from an opt into a pref. Updated testing docs and changed all uses to pref api. --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: --> - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [X] These changes fix #14960 (github issue number if applicable). <!-- Either: --> - [ ] There are tests for these changes OR - [X] These changes do not require tests because current test suite is sufficient <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. --> <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/15026) <!-- Reviewable:end -->
| @@ -56,6 +56,7 @@ | |||
| "layout.viewport.enabled": false, | |||
| "layout.writing-mode.enabled": false, | |||
| "network.mime.sniff": false, | |||
| "session-history.max-length":20, | |||
This comment has been minimized.
This comment has been minimized.
…PREF api updated test docs
|
@bors-servo: r+ |
|
|
|
|
Max session fix <!-- Please describe your changes on the following line: --> Converted document discarding from an opt into a pref. Updated testing docs and changed all uses to pref api. --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: --> - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [X] These changes fix #14960 (github issue number if applicable). <!-- Either: --> - [ ] There are tests for these changes OR - [X] These changes do not require tests because current test suite is sufficient <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. --> <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/15026) <!-- Reviewable:end -->
|
|
tydus101 commentedJan 14, 2017
•
edited by jdm
Converted document discarding from an opt into a pref. Updated testing docs and changed all uses to pref api.
./mach build -ddoes not report any errors./mach test-tidydoes not report any errorsThis change is