shithub: freetype+ttf2subf

Download patch

ref: 208e712de049f01d23e18dfe4fda5ee019fe5191
parent: 565f5a7d19d23aa7b3d6f917e5ef6b297b89f384
author: Werner Lemberg <[email protected]>
date: Mon Mar 27 16:56:23 EDT 2017

[cid, truetype] Don't use `index' as a variable name.

At least on FreeBSD there is a global declaration of `index' in file
`/usr/include/strings.h'.

* src/cff/cf2intrp.c, src/truetype/ttgload.c: s/index/idx/ where
appropriate.

git/fs: mount .git/fs: mount/attach disallowed
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2017-03-27  Werner Lemberg  <[email protected]>
+
+	[cid, truetype] Don't use `index' as a variable name.
+
+	At least on FreeBSD there is a global declaration of `index' in file
+	`/usr/include/strings.h'.
+
+	* src/cff/cf2intrp.c, src/truetype/ttgload.c: s/index/idx/ where
+	appropriate.
+
 2017-03-27  Wojciech Mamrak  <[email protected]>
 
 	[sfnt] Minor improvement for handling kern tables.
--- a/src/truetype/ttgload.c
+++ b/src/truetype/ttgload.c
@@ -1394,7 +1394,7 @@
   /* a utility function to retrieve i-th node from given FT_List */
   static FT_ListNode
   ft_list_get_node_at( FT_List  list,
-                       FT_UInt  index )
+                       FT_UInt  idx )
   {
     FT_ListNode  cur;
 
@@ -1404,10 +1404,10 @@
 
     for ( cur = list->head; cur; cur = cur->next )
     {
-      if ( !index )
+      if ( !idx )
         return cur;
 
-      index--;
+      idx--;
     }
 
     return NULL;