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

Speculative fix for NPE in linkifier #1703

Merged
merged 2 commits into from Sep 21, 2018
Merged

Conversation

Tyriar
Copy link
Member

@Tyriar Tyriar commented Sep 20, 2018

Fixes #1702


I was not able to repro this in the demo, but I think this will fix it.

@Tyriar Tyriar added this to the 3.8.0 milestone Sep 20, 2018
@Tyriar Tyriar self-assigned this Sep 20, 2018
@Tyriar Tyriar requested a review from jerch September 20, 2018 02:47
@Tyriar Tyriar changed the title Speculative fix for NPE Speculative fix for NPE in linkifier Sep 20, 2018
@jerch
Copy link
Member

jerch commented Sep 20, 2018

@Tyriar Any idea why .end can contain a stale value? Is there a caller that does not get informed about resize events?

@Tyriar
Copy link
Member Author

Tyriar commented Sep 20, 2018

@jerch my suspicion is it's happening because .end is only cleared at the end of that function, so if the resize happens during the setTimeout's delay it could repro. I tried to reproduce in the demo by increasing the delay but couldn't.

@Tyriar Tyriar merged commit 2e8e64e into xtermjs:master Sep 21, 2018
@Tyriar Tyriar deleted the 1702_isWrapped_fix branch September 21, 2018 16:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TypeError: Cannot read property 'isWrapped' of undefined at Buffer.getWrappedRangeForLine
2 participants