diff options
Diffstat (limited to 'vm_method.c')
| -rw-r--r-- | vm_method.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/vm_method.c b/vm_method.c index 5ef47e97ac..5a99f684c0 100644 --- a/vm_method.c +++ b/vm_method.c @@ -668,7 +668,7 @@ rb_vm_ci_lookup(ID mid, unsigned int flag, unsigned int argc, const struct rb_ca const struct rb_callinfo *ci = NULL; if (kwarg) { - ((struct rb_callinfo_kwarg *)kwarg)->references++; + RUBY_ATOMIC_FETCH_ADD(((struct rb_callinfo_kwarg *)kwarg)->references, 1); } struct rb_callinfo *new_ci = SHAREABLE_IMEMO_NEW(struct rb_callinfo, imemo_callinfo, (VALUE)kwarg); |
