Don't use stdlib.h and friends directly.

Reported by Mickey Gabel <mickey@monfort.co.il>.

* src/base/ftdbgmem.c: s/<stdlib.h>/FT_CONFIG_STANDARD_LIBRARY_H/.

* src/gzip/ftgzip.c, src/lzw/ftlzw.c, src/raster/ftmisc.h:
s/<string.h>/FT_CONFIG_STANDARD_LIBRARY_H/.

* src/autofit/aftypes.h, src/autofit/afhints.c,
src/pshinter/pshalgo.c: s/<stdio.h>/FT_CONFIG_STANDARD_LIBRARY_H/

* src/lzw/ftlzw.c, src/base/ftdbgmem.c: Don't include stdio.h.
This commit is contained in:
Werner Lemberg 2009-01-13 17:34:48 +00:00
parent f47acf2b5f
commit 24d72a1b0b
8 changed files with 29 additions and 14 deletions

View File

@ -1,3 +1,18 @@
2009-01-13 Werner Lemberg <wl@gnu.org>
Don't use stdlib.h and friends directly.
Reported by Mickey Gabel <mickey@monfort.co.il>.
* src/base/ftdbgmem.c: s/<stdlib.h>/FT_CONFIG_STANDARD_LIBRARY_H/.
* src/gzip/ftgzip.c, src/lzw/ftlzw.c, src/raster/ftmisc.h:
s/<string.h>/FT_CONFIG_STANDARD_LIBRARY_H/.
* src/autofit/aftypes.h, src/autofit/afhints.c,
src/pshinter/pshalgo.c: s/<stdio.h>/FT_CONFIG_STANDARD_LIBRARY_H/
* src/lzw/ftlzw.c, src/base/ftdbgmem.c: Don't include stdio.h.
2009-01-12 Werner Lemberg <wl@gnu.org>
Avoid compiler warnings.

View File

@ -127,7 +127,7 @@
#ifdef AF_DEBUG
#include <stdio.h>
#include FT_CONFIG_STANDARD_LIBRARY_H
static const char*
af_dir_str( AF_Direction dir )

View File

@ -4,7 +4,7 @@
/* */
/* Auto-fitter types (specification only). */
/* */
/* Copyright 2003, 2004, 2005, 2006, 2007, 2008 by */
/* Copyright 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, */
@ -58,7 +58,8 @@ FT_BEGIN_HEADER
#ifdef AF_DEBUG
#include <stdio.h>
#include FT_CONFIG_STANDARD_LIBRARY_H
#define AF_LOG( x ) do { if ( _af_debug ) printf x; } while ( 0 )
extern int _af_debug;

View File

@ -33,8 +33,7 @@
* memory, however.
*/
#include <stdio.h>
#include <stdlib.h>
#include FT_CONFIG_STANDARD_LIBRARY_H
FT_BASE_DEF( const char* ) _ft_debug_file = 0;
FT_BASE_DEF( long ) _ft_debug_lineno = 0;

View File

@ -8,7 +8,7 @@
/* parse compressed PCF fonts, as found with many X11 server */
/* distributions. */
/* */
/* Copyright 2002, 2003, 2004, 2005, 2006 by */
/* Copyright 2002, 2003, 2004, 2005, 2006, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@ -25,7 +25,7 @@
#include FT_INTERNAL_STREAM_H
#include FT_INTERNAL_DEBUG_H
#include FT_GZIP_H
#include <string.h>
#include FT_CONFIG_STANDARD_LIBRARY_H
#include FT_MODULE_ERRORS_H

View File

@ -8,7 +8,7 @@
/* be used to parse compressed PCF fonts, as found with many X11 server */
/* distributions. */
/* */
/* Copyright 2004, 2005, 2006 by */
/* Copyright 2004, 2005, 2006, 2009 by */
/* Albert Chin-A-Young. */
/* */
/* Based on code in src/gzip/ftgzip.c, Copyright 2004 by */
@ -27,8 +27,7 @@
#include FT_INTERNAL_STREAM_H
#include FT_INTERNAL_DEBUG_H
#include FT_LZW_H
#include <string.h>
#include <stdio.h>
#include FT_CONFIG_STANDARD_LIBRARY_H
#include FT_MODULE_ERRORS_H

View File

@ -4,7 +4,7 @@
/* */
/* PostScript hinting algorithm (body). */
/* */
/* Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by */
/* Copyright 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 */
@ -898,7 +898,7 @@
#ifdef DEBUG_ZONES
#include <stdio.h>
#include FT_CONFIG_STANDARD_LIBRARY_H
static void
psh_print_zone( PSH_Zone zone )

View File

@ -5,7 +5,7 @@
/* Miscellaneous macros for stand-alone rasterizer (specification */
/* only). */
/* */
/* Copyright 2005 by */
/* Copyright 2005, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used */
@ -27,7 +27,8 @@
#ifndef __FTMISC_H__
#define __FTMISC_H__
#include <string.h> /* memset */
/* memset */
#include FT_CONFIG_STANDARD_LIBRARY_H
#define FT_BEGIN_HEADER
#define FT_END_HEADER