[HarfBuzz] harfbuzz: Branch 'master'

Behdad Esfahbod behdad at kemper.freedesktop.org
Wed May 30 01:35:27 UTC 2018


 src/hb-map-private.hh |    7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

New commits:
commit a2444346220757e7743c972cbd24f925e72b419d
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Tue May 29 18:32:57 2018 -0700

    [map] Fix resize

diff --git a/src/hb-map-private.hh b/src/hb-map-private.hh
index aaf675aa..0baec082 100644
--- a/src/hb-map-private.hh
+++ b/src/hb-map-private.hh
@@ -110,9 +110,10 @@ struct hb_map_t
     items = new_items;
 
     /* Insert back old items. */
-    for (unsigned int i = 0; i < old_size; i++)
-      if (old_items[i].key != INVALID && old_items[i].value != INVALID)
-        set (old_items[i].key, old_items[i].value);
+    if (old_items)
+      for (unsigned int i = 0; i < old_size; i++)
+	if (old_items[i].key != INVALID && old_items[i].value != INVALID)
+	  set (old_items[i].key, old_items[i].value);
 
     free (old_items);
 


More information about the HarfBuzz mailing list