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

filters/thread_filter: fixed segfault on Ruby 2.1.3 #231

Merged
merged 1 commit into from
Jun 7, 2017

Conversation

kyrylo
Copy link
Contributor

@kyrylo kyrylo commented Jun 7, 2017

Fixes #229 (Another segfault report)

Ruby segfaults whenever it tries to access :__recursive_key__.
Unfortunately, there's no other good way to avoid this segfault.
:__recursive_key__ is set by PrettyPrint, so it's very common.

@kyrylo kyrylo force-pushed the 229-segfault-fix branch from 6d5cbe0 to 4a3034f Compare June 7, 2017 15:45
@@ -57,6 +64,7 @@ def thread_variables(th)

def fiber_variables(th)
th.keys.map.with_object({}) do |key, h|
next if IGNORED_FIBER_VARIABLES.any? { |v| v == key }
Copy link

@vmihailenco vmihailenco Jun 7, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we ignore all vars that start with _? I wanted to suggest this before, but did not want to complicate without a good reason.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good.

@kyrylo kyrylo force-pushed the 229-segfault-fix branch 3 times, most recently from 8d2182a to ea083a5 Compare June 7, 2017 17:21
Fixes #229 (Another segfault report)

Ruby segfaults whenever it tries to access `:__recursive_key__`.
Unfortunately, there's no other good way to avoid this segfault.
`:__recursive_key__` is set by PrettyPrint, so it's very common.
@kyrylo kyrylo force-pushed the 229-segfault-fix branch from ea083a5 to c338719 Compare June 7, 2017 17:29
@kyrylo kyrylo merged commit 0b0d250 into master Jun 7, 2017
@kyrylo kyrylo deleted the 229-segfault-fix branch June 7, 2017 17:43
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.

2 participants