summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAaron Patterson <tenderlove@ruby-lang.org>2020-10-28 10:16:57 -0700
committerAaron Patterson <tenderlove@ruby-lang.org>2020-10-28 10:16:57 -0700
commita99f52d5113a601b6d18bd671dfee24266689ffe (patch)
treee7ee1d2f1f0319e58353c0a4549570da42746802
parent5be42c1ef4f7ed0a8004cad750a9ce61869bd768 (diff)
Remove another unnecessary test
Same as 5be42c1ef4f7ed0a8004cad750a9ce61869bd768
-rw-r--r--gc.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/gc.c b/gc.c
index 58541a4..dd9f091 100644
--- a/gc.c
+++ b/gc.c
@@ -8207,11 +8207,9 @@ gc_ref_update_object(rb_objspace_t * objspace, VALUE v)
{
VALUE *ptr = ROBJECT_IVPTR(v);
- if (ptr) {
- uint32_t i, len = ROBJECT_NUMIV(v);
- for (i = 0; i < len; i++) {
- UPDATE_IF_MOVED(objspace, ptr[i]);
- }
+ uint32_t i, len = ROBJECT_NUMIV(v);
+ for (i = 0; i < len; i++) {
+ UPDATE_IF_MOVED(objspace, ptr[i]);
}
}