shithub: freetype+ttf2subf

Download patch

ref: 9bf73ec40798148639be45eadbec22d50dd7f8a4
parent: 24d72a1b0b3d7227000a8b9a54f3513f99c7fe4e
author: Werner Lemberg <[email protected]>
date: Tue Jan 13 12:42:00 EST 2009

Fix C++ compilation.

* src/base/ftobjs.c (FT_Get_FSType_Flags): Cast for compilation
with C++.

git/fs: mount .git/fs: mount/attach disallowed
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 2009-01-13  Werner Lemberg  <[email protected]>
 
+	* src/base/ftobjs.c (FT_Get_FSType_Flags): Cast for compilation
+	with C++.
+
+2009-01-13  Werner Lemberg  <[email protected]>
+
 	Don't use stdlib.h and friends directly.
 	Reported by Mickey Gabel <[email protected]>.
 
--- a/src/base/ftobjs.c
+++ b/src/base/ftobjs.c
@@ -4,7 +4,7 @@
 /*                                                                         */
 /*    The FreeType private base classes (body).                            */
 /*                                                                         */
-/*  Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by       */
+/*  Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -4393,8 +4393,8 @@
          font_info.fs_type != 0                   )
       return font_info.fs_type;
 
-    if ( ( os2 = FT_Get_Sfnt_Table( face, ft_sfnt_os2 ) ) != NULL &&
-         os2->version != 0xFFFFU                                  )
+    if ( ( os2 = (TT_OS2*)FT_Get_Sfnt_Table( face, ft_sfnt_os2 ) ) != NULL &&
+         os2->version != 0xFFFFU                                           )
       return os2->fsType;
 
     return 0;