From f17ed90f7704d77e3eb59a6f6b693ab4c598936a Mon Sep 17 00:00:00 2001 From: Joshua Haberman Date: Thu, 27 Aug 2009 11:10:13 -0700 Subject: Some cleanup and reformatting, fixed the benchmarks. --- src/upb_mm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/upb_mm.c') diff --git a/src/upb_mm.c b/src/upb_mm.c index 853d572..769db96 100644 --- a/src/upb_mm.c +++ b/src/upb_mm.c @@ -27,7 +27,7 @@ void upb_array_destroy(struct upb_array *arr) upb_arraylen_t i; /* Unref elements. */ for(i = 0; i < arr->len; i++) { - union upb_value_ptr p = upb_array_getelementptr(arr, i, arr->fielddef->type); + union upb_value_ptr p = upb_array_getelementptr(arr, i); upb_mm_ptrtype type = upb_elem_ptrtype(arr->fielddef); union upb_mmptr mmptr = upb_mmptr_read(p, type); upb_mm_unref(mmptr, type); @@ -120,7 +120,7 @@ struct upb_mm_ref *upb_mm_getelemref(struct upb_mm_ref *arrref, upb_arraylen_t i struct upb_msg_fielddef *f = arr->fielddef; assert(upb_elem_ismm(f)); assert(i < arr->len); - union upb_value_ptr p = upb_array_getelementptr(arr, i, f->type); + union upb_value_ptr p = upb_array_getelementptr(arr, i); upb_mm_ptrtype type = upb_elem_ptrtype(f); union upb_mmptr val = upb_mmptr_read(p, type); return find_or_create_ref(arrref, arrref->mm, val, type, refcreated); -- cgit v1.2.3