[Fontconfig] fontconfig: Branch 'master' - 2 commits

Behdad Esfahbod behdad at kemper.freedesktop.org
Wed Aug 6 09:23:43 PDT 2014


 src/fcweight.c |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 01bb6978b6389852c5259b135af45ecdfe9f42f8
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Wed Aug 6 12:23:24 2014 -0400

    Fix assertion failure
    
    https://bugs.freedesktop.org/show_bug.cgi?id=82220
    https://bugs.freedesktop.org/show_bug.cgi?id=82228

diff --git a/src/fcweight.c b/src/fcweight.c
index c62f807..313f3f2 100644
--- a/src/fcweight.c
+++ b/src/fcweight.c
@@ -45,7 +45,7 @@ static int lerp(int x, int x1, int x2, int y1, int y2)
 {
   int dx = x2 - x1;
   int dy = y2 - y1;
-  assert (dx > 0 && dy > 0 && x1 <= x && x <= x2);
+  assert (dx > 0 && dy >= 0 && x1 <= x && x <= x2);
   return y1 + (dy*(x-x1) + dx/2) / dx;
 }
 
commit 37e501ed0af9b1f68f64600e00e90809e19f9302
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Sun Jul 27 16:53:28 2014 -0400

    Remove unneeded FcPublic

diff --git a/src/fcweight.c b/src/fcweight.c
index 87bbe67..c62f807 100644
--- a/src/fcweight.c
+++ b/src/fcweight.c
@@ -49,7 +49,7 @@ static int lerp(int x, int x1, int x2, int y1, int y2)
   return y1 + (dy*(x-x1) + dx/2) / dx;
 }
 
-FcPublic int
+int
 FcWeightFromOpenType (int ot_weight)
 {
 	int i;
@@ -66,7 +66,7 @@ FcWeightFromOpenType (int ot_weight)
 	return lerp (ot_weight, map[i-1].ot, map[i].ot, map[i-1].fc, map[i].fc);
 }
 
-FcPublic int
+int
 FcWeightToOpenType (int fc_weight)
 {
 	int i;


More information about the Fontconfig mailing list