shithub: freetype+ttf2subf

Download patch

ref: 1f377f0d50a6a4bdf2a4985a010af0403925681f
parent: 0814b80fdeb473367e2890a7c1f20e7d4735d467
author: Werner Lemberg <[email protected]>
date: Mon Feb 16 03:37:09 EST 2015

* src/base/ftsystem.c: Use casts in standard C function wrappers.
(ft_alloc, ft_realloc, ft_ansi_stream_io, FT_Stream_Open): Do it.

git/fs: mount .git/fs: mount/attach disallowed
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 2015-02-16  Werner Lemberg  <[email protected]>
 
+	* src/base/ftsystem.c: Use casts in standard C function wrappers.
+	(ft_alloc, ft_realloc, ft_ansi_stream_io, FT_Stream_Open): Do it.
+
+2015-02-16  Werner Lemberg  <[email protected]>
+
 	Fix Savannah bug #44261.
 
 	* builds/unix/detect.mk (setup) [unix]: Set `CONFIG_SHELL' in the
--- a/src/base/ftsystem.c
+++ b/src/base/ftsystem.c
@@ -71,7 +71,7 @@
   {
     FT_UNUSED( memory );
 
-    return ft_smalloc( size );
+    return ft_smalloc( (size_t)size );
   }
 
 
@@ -104,7 +104,7 @@
     FT_UNUSED( memory );
     FT_UNUSED( cur_size );
 
-    return ft_srealloc( block, new_size );
+    return ft_srealloc( block, (size_t)new_size );
   }
 
 
@@ -212,7 +212,7 @@
     file = STREAM_FILE( stream );
 
     if ( stream->pos != offset )
-      ft_fseek( file, offset, SEEK_SET );
+      ft_fseek( file, (long)offset, SEEK_SET );
 
     return (unsigned long)ft_fread( buffer, 1, count, file );
   }
@@ -247,7 +247,7 @@
     }
 
     ft_fseek( file, 0, SEEK_END );
-    stream->size = ft_ftell( file );
+    stream->size = (unsigned long)ft_ftell( file );
     if ( !stream->size )
     {
       FT_ERROR(( "FT_Stream_Open:" ));