[HarfBuzz] harfbuzz-ng: Branch 'master'

Behdad Esfahbod behdad at kemper.freedesktop.org
Tue Jul 24 12:02:43 PDT 2012


 src/hb-shape.cc |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 97aa0b738a33b73a3f9763dd2950f2dd39f596ed
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Tue Jul 24 15:02:34 2012 -0400

    Minor const correctness shuffling

diff --git a/src/hb-shape.cc b/src/hb-shape.cc
index 56c9046..60a2dce 100644
--- a/src/hb-shape.cc
+++ b/src/hb-shape.cc
@@ -68,13 +68,13 @@ static const struct hb_shaper_pair_t {
 
 /* Thread-safe, lock-free, shapers */
 
-static hb_shaper_pair_t *static_shapers;
+static const hb_shaper_pair_t *static_shapers;
 
 static
 void free_static_shapers (void)
 {
   if (unlikely (static_shapers != all_shapers))
-    free (static_shapers);
+    free ((void *) static_shapers);
 }
 
 static const hb_shaper_pair_t *
@@ -87,7 +87,7 @@ retry:
   {
     char *env = getenv ("HB_SHAPER_LIST");
     if (!env || !*env) {
-      (void) hb_atomic_ptr_cmpexch (&static_shapers, NULL, (const hb_shaper_pair_t *) all_shapers);
+      (void) hb_atomic_ptr_cmpexch (&static_shapers, NULL, &all_shapers[0]);
       return (const hb_shaper_pair_t *) all_shapers;
     }
 



More information about the HarfBuzz mailing list