From aaffe41094f8ddefad6f33e86cbd04a24dd9bfff Mon Sep 17 00:00:00 2001 From: Ebrahim Byagowi Date: Fri, 26 Jul 2019 01:14:37 +0430 Subject: [PATCH] [meta] minor, simplify iterator --- src/hb-ot-meta-table.hh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/hb-ot-meta-table.hh b/src/hb-ot-meta-table.hh index cc31bfb..37f627c 100644 --- a/src/hb-ot-meta-table.hh +++ b/src/hb-ot-meta-table.hh @@ -82,11 +82,11 @@ struct meta unsigned int *count, hb_ot_meta_t *entries) const { - if (count && *count) + if (count) { - hb_array_t array = table->dataMaps.sub_array (start_offset, count); - for (unsigned int i = 0; i < *count; i++) - entries[i] = (hb_ot_meta_t) array[i].get_tag (); + hb_array_t arr = table->dataMaps.sub_array (start_offset, count); + for (unsigned int i = 0; i < arr.length; i++) + entries[i] = (hb_ot_meta_t) arr[i].get_tag (); } return table->dataMaps.len; } -- 2.7.4