Auto merge of #21353 - DanxiongLei:damonlei_fix, r=jdm

fix(webgl): fix issue https://github.com/servo/servo/issues/21352

If we have a bounded framebuffer previously, which is not the one to delete.
we would not change the !binding, but we would change the GLSide with Command::BindFramebuffer(Default).

change it to:

check the id before sending the Command

---

- [ ] `./mach build -d` does not report any errors
- [ ] `./mach test-tidy` does not report any errors
- [x] These changes fix #21352

- [ ] There are tests for these changes OR
- [x] These changes do not require tests because `it's obviously simple.`

<!-- 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/21353)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2018-09-19 13:36:24 -04:00 committed by GitHub
commit b1c6281d3c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -92,12 +92,11 @@ macro_rules! handle_object_deletion {
if let Some(bound_object) = $binding.get() {
if bound_object.id() == $object.id() {
$binding.set(None);
}
if let Some(command) = $unbind_command {
$self_.send_command(command);
}
}
}
};
}