Commit ca6a5cf4b85db512402be7fa45a7b05f4e8baa60

Werner Lemberg 2015-08-03T08:51:18

Fix typo in clang bug from 2015-07-31 (#45678). * src/base/ftrfork.c (FT_Raccess_Get_HeaderInfo): Fix inequality.

diff --git a/ChangeLog b/ChangeLog
index 7b35ece..58c61ac 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2015-08-03  Werner Lemberg  <wl@gnu.org>
+
+	Fix typo in clang bug from 2015-07-31 (#45678).
+
+	* src/base/ftrfork.c (FT_Raccess_Get_HeaderInfo): Fix inequality.
+
 2015-08-02  Werner Lemberg  <wl@gnu.org>
 
 	* CMakeLists.txt: Improve shared library support.
diff --git a/src/base/ftrfork.c b/src/base/ftrfork.c
index 702f639..c30c766 100644
--- a/src/base/ftrfork.c
+++ b/src/base/ftrfork.c
@@ -93,8 +93,8 @@
     if ( *rdata_pos != map_pos - rdata_len || map_pos == 0 )
       return FT_THROW( Unknown_File_Format );
 
-    if ( FT_LONG_MAX - rfork_offset > *rdata_pos ||
-         FT_LONG_MAX - rfork_offset > map_pos    )
+    if ( FT_LONG_MAX - rfork_offset < *rdata_pos ||
+         FT_LONG_MAX - rfork_offset < map_pos    )
       return FT_THROW( Unknown_File_Format );
 
     *rdata_pos += rfork_offset;