Skip to content

Miscellaneous fixes to harden the constellation. - #10295

Merged
bors-servo merged 1 commit into
servo:masterfrom
asajeffrey:remove-constellation-misc-panic
Apr 1, 2016
Merged

bors-servo merged 1 commit into
servo:masterfrom
asajeffrey:remove-constellation-misc-panic

Conversation

@asajeffrey

Copy link
Copy Markdown
Contributor

This change is Reviewable

@highfive highfive added the S-awaiting-review There is new code that needs to be reviewed. label Mar 30, 2016
@asajeffrey

Copy link
Copy Markdown
Contributor Author

Part of #10124 constellation hardening.

@nox

nox commented Mar 31, 2016

Copy link
Copy Markdown
Contributor

A few nits, feel free to r=me when you address them.

-S-awaiting-review +S-needs-code-changes


Reviewed 1 of 1 files at r1.
Review status: all files reviewed at latest revision, 5 unresolved discussions.


components/compositing/constellation.rs, line 714 [r1] (raw file):
Nit: please no unwrap_or_else for side-effects.


components/compositing/constellation.rs, line 1498 [r1] (raw file):
Nit: Please no unwrap_or_else for side-effects.


components/compositing/constellation.rs, line 1574 [r1] (raw file):
Nit: self.frames.remove(&frame_id).is_none()


components/compositing/constellation.rs, line 1575 [r1] (raw file):
I wonder, this could also happen if it receives a nonsensical frame_id value, right? So shouldn't this message just be about not finding a frame?


components/compositing/constellation.rs, line 1606 [r1] (raw file):
Shouldn't this message just be about not finding a pipeline?


Comments from the review on Reviewable.io

@nox nox added S-needs-code-changes Changes have not yet been made that were requested by a reviewer. and removed S-awaiting-review There is new code that needs to be reviewed. labels Mar 31, 2016
@nox nox assigned nox and unassigned larsbergstrom Mar 31, 2016
@asajeffrey

Copy link
Copy Markdown
Contributor Author

I'll submit another PR replacing unwrap_or_else by if let.


Review status: all files reviewed at latest revision, 5 unresolved discussions.


components/compositing/constellation.rs, line 1575 [r1] (raw file):
Well... the FrameId is only created by new_frame, which adds the id to the frames hash map, then only removed by close_frame. So the debug message is correct (and if we reword this one, we should probably reword all the other ones too, there's quite a lot of them in other PRs!).


components/compositing/constellation.rs, line 1606 [r1] (raw file):
Ditto.


Comments from the review on Reviewable.io

@asajeffrey

Copy link
Copy Markdown
Contributor Author

I should clarify: I can't submit a PR replacing unwrap_or_else by if let until this PR lands.

@asajeffrey

Copy link
Copy Markdown
Contributor Author

@bors-servo

Copy link
Copy Markdown
Contributor

📌 Commit f9f1587 has been approved by nox

@highfive highfive added S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. and removed S-needs-code-changes Changes have not yet been made that were requested by a reviewer. labels Mar 31, 2016
asajeffrey pushed a commit to asajeffrey/servo that referenced this pull request Mar 31, 2016
@bors-servo

Copy link
Copy Markdown
Contributor

⌛ Testing commit f9f1587 with merge 7f06b46...

bors-servo pushed a commit that referenced this pull request Apr 1, 2016
@bors-servo

Copy link
Copy Markdown
Contributor

☀️ Test successful - android, arm32, linux-dev, linux-rel, mac-dev-unit, mac-rel-css, mac-rel-wpt, status-appveyor

@bors-servo
bors-servo merged commit f9f1587 into servo:master Apr 1, 2016
asajeffrey pushed a commit to asajeffrey/servo that referenced this pull request Apr 1, 2016
asajeffrey pushed a commit to asajeffrey/servo that referenced this pull request Apr 11, 2016
asajeffrey pushed a commit to asajeffrey/servo that referenced this pull request Apr 12, 2016
asajeffrey pushed a commit to asajeffrey/servo that referenced this pull request Apr 13, 2016
asajeffrey pushed a commit to asajeffrey/servo that referenced this pull request Apr 14, 2016
bors-servo pushed a commit that referenced this pull request Apr 15, 2016
Replace side-effecting unwrap_or_else by if let in constellation.

This addresses @nox's comments in #10295.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/10345)
<!-- Reviewable:end -->
asajeffrey pushed a commit to asajeffrey/servo that referenced this pull request Apr 15, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants