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

Synchronize state in AbstractVariable and Argv #8232

Merged
merged 1 commit into from May 15, 2024

Conversation

headius
Copy link
Member

@headius headius commented May 9, 2024

These fields are changed together but without any synchronization or atomicity. Simplest fix for now is to synchronize the methods and mark them as volatile.

Fixes #8178

I looked over other descendants of AbstractVariable but none of them had state changes like Argv.

I also tried to figure out a way to encapsulate those fields better but I will look at that a different time after learning why these variables work this way.

These fields are changed together but without any synchronization
or atomicity. Simplest fix for now is to synchronize the methods
and mark them as volatile.

Fixes jruby#8178
@headius headius added this to the JRuby 9.4.8.0 milestone May 9, 2024
@headius headius merged commit 733d2c4 into jruby:master May 15, 2024
73 of 74 checks passed
@headius headius deleted the argv_embedding_synchronization branch May 15, 2024 04:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant