Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

panicking when loading agar.io #10952

Closed
lhirlimann opened this issue May 1, 2016 · 5 comments · Fixed by #11934
Closed

panicking when loading agar.io #10952

lhirlimann opened this issue May 1, 2016 · 5 comments · Fixed by #11934
Assignees
Labels
A-constellation Involves the constellation A-content/dom Interacting with the DOM from web content I-panic Servo encounters a panic. I-perf-bloat Unnecessary memory usage.

Comments

@lhirlimann
Copy link

[ludo@Oulanl servo]$ ./mach run --release http://www.agar.io
ERROR:js::rust: Error at http://agar.io/js/a.js?a&ad_box_:0:0: document.write is not a function

ERROR:js::rust: Error at http://staticxx.facebook.com/connect/xd_arbiter.php?version=42#cb=f381742319487ba&domain=agar.io&origin=http%3A%2F%2Fagar.io%2Ff7bb7fb0cb1716&relation=parent&error=unknown_user:47:1880: window.name is undefined

ERROR:js::rust: Error at http://agar.io/js/master.js:2:23299: o is undefined

ERROR:js::rust: Error at https://apis.google.com/_/scs/apps-static/_/js/k=oz.gapi.fr.0JX4waWGXC4.O/m=client/rt=j/sv=1/d=1/ed=1/am=AQ/rs=AGLTcCOmGNu6CSHv8uZNgXAzhVDn7pAJ9Q/cb=gapi.loaded_0:10:32: c is undefined

thread 'ImageCacheThread' panicked at 'called Result::unwrap() on an Err value: Error { repr: Os { code: 9, message: "Bad file descriptor" } }', ../src/libcore/result.rs:785
stack backtrace:
1: 0x561b5f080690 -
2: 0x561b5f087cab -
3: 0x561b5f087913 -
thread '

' panicked at 'called Result::unwrap() on an Err value: Error { repr: Os { code: 9, message: "Bad file descriptor" } }', ../src/libcore/result.rs:785
4: 0x561b5e6b66a6 -
5: 0x561b5f06dd33 -
6: 0x561b5f06f778 -
7: 0x561b5f07f8e1 -
8: 0x561b5f0bf62f -
9: 0x561b5d91f105 -
thread 'PaintWorker' panicked at 'called Result::unwrap() on an Err value: Error { repr: Os { code: 9, message: "Bad file descriptor" } }', ../src/libcore/result.rs:785
10: 0x561b5dbb8392 -
11: 0x561b5dbe26aa -
12: 0x561b5f07f86b -
13: 0x561b5f07f7fd -
14: 0x561b5dbe2afdthread 'PaintWorker' panicked at 'called Result::unwrap() on an Err value: Error { repr: Os { code: 9, message: "Bad file descriptor" } }', ../src/libcore/result.rs:785
thread 'PaintWorker' panicked at 'assertion failed: thread::panicking() || result == 0', /home/ludo/servo/.cargo/git/checkouts/ipc-channel-3840821e54ea11a6/master/platform/linux/mod.rs:95
thread 'PaintWorker' panicked at 'assertion failed: thread::panicking() || result == 0', /home/ludo/servo/.cargo/git/checkouts/ipc-channel-3840821e54ea11a6/master/platform/linux/mod.rs:95
thread 'PaintWorker' panicked at 'assertion failed: thread::panicking() || result == 0', /home/ludo/servo/.cargo/git/checkouts/ipc-channel-3840821e54ea11a6/master/platform/linux/mod.rs:95

  • 15: 0x561b5f086194 - 16: 0x7fd14b9f2589 - 17: 0x7fd14b5115cc - 18: 0x0 - stack backtrace: 1: 0x561b5f080690 - 2: 0x561b5f087cab - 3: 0x561b5f087913 - 4: 0x561b5e6b66a6 - 5: 0x561b5f06dd33 - 6: 0x561b5f06f778 - 7: 0x561b5f07f8e1 - 8: 0x561b5f0bf62f - 9: 0x561b5d91f105 - 10: 0x561b5e5d3827 - 11: 0x561b5e5d435b - 12: 0x561b5d6e617d - 13: 0x561b5d6edcfe - 14: 0x561b5d6c04c4 - 15: 0x561b5d6f7ffc - 16: 0x561b5d6a8065 - 17: 0x561b5f0873b4 - 18: 0x561b5f07f86b - 19: 0x561b5f086dfb - 20: 0x7fd14b426720 - 21: 0x561b5d6a6268 - 22: 0x0 - stack backtrace: 1: 0x561b5f080690 - 2: 0x561b5f087cab - 3: 0x561b5f087913 - 4: 0x561b5e6b66a6 - 5: 0x561b5f06dd33 - 6: 0x561b5f06f778 - 7: 0x561b5f07f8e1 - 8: 0x561b5f0bf62f - 9: 0x561b5d91f105 - 10: 0x561b5e5d3827 - 11: 0x561b5e5d435b - 12: 0x561b5e3593bf - 13: 0x561b5e357127 - 14: 0x561b5f07f86b - 15: 0x561b5f07f7fd - 16: 0x561b5e357841 - 17: 0x561b5f086194 - 18: 0x7fd14b9f2589 - 19: 0x7fd14b5115cc - 20: 0x0 - stack backtrace: 1: 0x561b5f080690 - 2: 0x561b5f087cab - 3: 0x561b5f087913 - 4: 0x561b5e6b66a6 - 5: 0x561b5f06dd33 - 6: 0x561b5f06f778 - 7: 0x561b5f07f8e1 - 8: 0x561b5f0bf62f - 9: 0x561b5d91f105 - 10: 0x561b5e5d3827 - 11: 0x561b5e5d435b - 12: 0x561b5e3593bf - 13: 0x561b5e357127 - 14: 0x561b5f07f86b - 15: 0x561b5f07f7fd - 16: 0x561b5e357841 - 17: 0x561b5f086194 - 18: 0x7fd14b9f2589 - 19: 0x7fd14b5115cc - 20: 0x0 - stack backtrace: thread 'PaintWorker' panicked at 'called `Result::unwrap()` on an `Err` value: Error { repr: Os { code: 9, message: "Bad file descriptor" } }', ../src/libcore/result.rs:785 1: 0x561b5f080690 - 2: 0x561b5f087cab - 3: 0x561b5f087913 - 4: 0x561b5e6b66a6 - 5: 0x561b5f06dd33 - 6: 0x561b5d91de6f - 7: 0x561b5ed0f650 - 8: 0x561b5e35710d - 9: 0x561b5f07f86b - 10: 0x561b5f07f7fd - 11: 0x561b5e357841 - 12: 0x561b5f086194 - 13: 0x7fd14b9f2589 - 14: 0x7fd14b5115cc - 15: 0x0 - stack backtrace: 1: 0x561b5f080690 - 2: 0x561b5f087cab - 3: 0x561b5f087913 - 4: 0x561b5e6b66a6 - 5: 0x561b5f06dd33 - 6: 0x561b5d91de6f - 7: 0x561b5ed0f650 - 8: 0x561b5e35710d - 9: 0x561b5f07f86b - 10: 0x561b5f07f7fd - 11: 0x561b5e357841 - 12: 0x561b5f086194 - 13: 0x7fd14b9f2589 - 14: 0x7fd14b5115cc - 15: 0x0 - stack backtrace: 1: 0x561b5f080690 - 2: 0x561b5f087cab - 3: 0x561b5f087913 - 4: 0x561b5e6b66a6 - 5: 0x561b5f06dd33 - thread '' panicked at 'You should have disposed of the pixmap properly with destroy()! This pixmap will leak! ', /home/ludo/servo/.cargo/git/checkouts/rust-layers-c02709c0157e02cd/master/src/platform/linux/surface.rs :6196: 0x561b5d91de6f - 7: 0x561b5ed0f650 - 8: 0x561b5e35710d - 9: 0x561b5f07f86b - 10: 0x561b5f07f7fd - 11: 0x561b5e357841 - 12: 0x561b5f086194 - 13: 0x7fd14b9f2589 - 14: 0x7fd14b5115cc - 15: 0x0 - stack backtrace: 1: 0x561b5f080690 - 2: 0x561b5f087cab - 3: 0x561b5f087913 - 4: 0x561b5e6b66a6 - 5: 0x561b5f06dd33 - 6: 0x561b5f06f778 - 7: 0x561b5f07f8e1 - 8: 0x561b5f0bf62f - 9: 0x561b5d91f105 - 10: 0x561b5e5d3827 - 11: 0x561b5e5d435b - 12: 0x561b5e3593bf - 13: 0x561b5e357127 - 14: 0x561b5f07f86b - 15: 0x561b5f07f7fd - 16: 0x561b5e357841 - 17: 0x561b5f086194 - 18: 0x7fd14b9f2589 - 19: 0x7fd14b5115cc - 20: 0x0 - stack backtrace: 1: 0x561b5f080690 - 2: 0x561b5f087cab - 3: 0x561b5f087913 - 4: 0x561b5e6b66a6 - 5: 0x561b5f06dd33 - 6: 0x561b5d91de6f - 7: 0x561b5ed24060 - 8: 0x561b5d6ba0eb - 9: 0x561b5d6b9f77 - 10: 0x561b5d6b9f77 - 11: 0x561b5d6bbdd1 - 12: 0x561b5d6a8113 - 13: 0x561b5f0873b4 - 14: 0x561b5f07f86b - 15: 0x561b5f086dfb - 16: 0x7fd14b426720 - 17: 0x561b5d6a6268 - 18: 0x0 - thread panicked while panicking. aborting. Servo exited with return value -4 [ludo@Oulanl servo]$
@jdm jdm added the I-panic Servo encounters a panic. label May 1, 2016
@jdm
Copy link
Member

jdm commented May 1, 2016

lldb shows me that there are 2051 threads currently active when I lose the ability to spawn more. The vast majority that I see are LayoutWorker and PaintWorker, which I find really interesting.

@jdm jdm added the I-perf-bloat Unnecessary memory usage. label May 1, 2016
@jdm
Copy link
Member

jdm commented May 1, 2016

This happens because an iframe sets location.hash to an empty string, which causes us to reload the page and create a new pipeline to do so. This repeats endlessly.

@jdm jdm added the A-constellation Involves the constellation label May 1, 2016
@jdm
Copy link
Member

jdm commented May 1, 2016

We're missing step 6 of https://html.spec.whatwg.org/multipage/browsers.html#navigate which would cause us to abort the navigation in this case.

@jdm jdm added the A-content/dom Interacting with the DOM from web content label May 1, 2016
@jdm
Copy link
Member

jdm commented May 1, 2016

Rather, the implementation in handle_navigate relies on a fragment existing, which doesn't match the specification.

@jdm jdm self-assigned this May 1, 2016
@jdm
Copy link
Member

jdm commented May 2, 2016

This is also visible at https://login.comcast.net/login. The same facebook iframe as agar.io is responsible for an endless chain of page loads.

bors-servo pushed a commit that referenced this issue Jun 29, 2016
Special-case setting location.hash to the empty string

This avoids endless redirect loops on facebook and makes us compliant with whatwg/html#1318.

---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #10952
- [X] There are tests for these changes OR

<!-- 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/11934)
<!-- Reviewable:end -->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-constellation Involves the constellation A-content/dom Interacting with the DOM from web content I-panic Servo encounters a panic. I-perf-bloat Unnecessary memory usage.
Projects
None yet
2 participants