Commit 553c9672b35dd39e4ccfe564084ec67bd218d45f

Werner Lemberg 2014-12-07T19:29:52

Work around a bug in Borland's C++ compiler. See http://qc.embarcadero.com/wc/qcmain.aspx?d=118998 for Borland's bug tracker entry. Reported by Yuliana Zigangirova <zigangirova@inbox.ru>, http://lists.gnu.org/archive/html/freetype-devel/2014-04/msg00001.html. * include/internal/ftvalid.h (FT_ValidatorRec), src/smooth/ftgrays.c (gray_TWorker_): Move `ft_jmp_buf' field to be the first element.

diff --git a/ChangeLog b/ChangeLog
index 3d6a0ae..afc342f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,21 @@
 2014-12-07  Werner Lemberg  <wl@gnu.org>
 
+	Work around a bug in Borland's C++ compiler.
+
+	See
+
+	  http://qc.embarcadero.com/wc/qcmain.aspx?d=118998
+
+	for Borland's bug tracker entry.
+
+	Reported by Yuliana Zigangirova <zigangirova@inbox.ru>,
+	http://lists.gnu.org/archive/html/freetype-devel/2014-04/msg00001.html.
+
+	* include/internal/ftvalid.h (FT_ValidatorRec), src/smooth/ftgrays.c
+	(gray_TWorker_): Move `ft_jmp_buf' field to be the first element.
+
+2014-12-07  Werner Lemberg  <wl@gnu.org>
+
 	*/*: Decorate hex constants with `U' and `L' where appropriate.
 
 2014-12-07  Werner Lemberg  <wl@gnu.org>
diff --git a/include/internal/ftvalid.h b/include/internal/ftvalid.h
index 12ad036..5459738 100644
--- a/include/internal/ftvalid.h
+++ b/include/internal/ftvalid.h
@@ -87,13 +87,13 @@ FT_BEGIN_HEADER
   /* validator structure */
   typedef struct  FT_ValidatorRec_
   {
+    ft_jmp_buf          jump_buffer; /* used for exception handling      */
+
     const FT_Byte*      base;        /* address of table in memory       */
     const FT_Byte*      limit;       /* `base' + sizeof(table) in memory */
     FT_ValidationLevel  level;       /* validation level                 */
     FT_Error            error;       /* error returned. 0 means success  */
 
-    ft_jmp_buf          jump_buffer; /* used for exception handling      */
-
   } FT_ValidatorRec;
 
 #if defined( _MSC_VER )
diff --git a/src/smooth/ftgrays.c b/src/smooth/ftgrays.c
index 9d37d64..131ad27 100644
--- a/src/smooth/ftgrays.c
+++ b/src/smooth/ftgrays.c
@@ -405,6 +405,8 @@ typedef ptrdiff_t  FT_PtrDist;
 
   typedef struct  gray_TWorker_
   {
+    ft_jmp_buf  jump_buffer;
+
     TCoord  ex, ey;
     TPos    min_ex, max_ex;
     TPos    min_ey, max_ey;
@@ -440,8 +442,6 @@ typedef ptrdiff_t  FT_PtrDist;
     int  band_size;
     int  band_shoot;
 
-    ft_jmp_buf  jump_buffer;
-
     void*       buffer;
     long        buffer_size;