gzip: Use FT2 zcalloc() & zfree() in ftgzip.c by default.
This commit is contained in:
parent
5f43bab8bf
commit
a8c515d25c
11
ChangeLog
11
ChangeLog
|
@ -1,3 +1,14 @@
|
||||||
|
2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
|
||||||
|
|
||||||
|
gzip: Use FT2 zcalloc() & zfree() in ftgzip.c by default.
|
||||||
|
|
||||||
|
* src/gzip/ftgzip.c (zcalloc, zcfree): Disable all
|
||||||
|
zcalloc() & zfree() by zlib in zutil.c, those in
|
||||||
|
ftgzip.c by FT2 are enabled by default. To use
|
||||||
|
zlib zcalloc() & zfree(), define USE_ZLIB_ZCALLOC.
|
||||||
|
See discussion:
|
||||||
|
http://lists.gnu.org/archive/html/freetype-devel/2009-02/msg00000.html
|
||||||
|
|
||||||
2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
|
2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
|
||||||
|
|
||||||
gzip: Distinguish PureC from TurboC on MSDOS.
|
gzip: Distinguish PureC from TurboC on MSDOS.
|
||||||
|
|
|
@ -58,7 +58,9 @@
|
||||||
/* original ZLib. */
|
/* original ZLib. */
|
||||||
|
|
||||||
#define NO_DUMMY_DECL
|
#define NO_DUMMY_DECL
|
||||||
#define MY_ZCALLOC
|
#ifndef USE_ZLIB_ZCALLOC
|
||||||
|
#define MY_ZCALLOC /* prevent all zcalloc() & zfree() in zutils.c */
|
||||||
|
#endif
|
||||||
|
|
||||||
#include "zlib.h"
|
#include "zlib.h"
|
||||||
|
|
||||||
|
@ -121,7 +123,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
#ifndef FT_CONFIG_OPTION_SYSTEM_ZLIB
|
#if !defined( FT_CONFIG_OPTION_SYSTEM_ZLIB ) && !defined( USE_ZLIB_ZCALLOC )
|
||||||
|
|
||||||
local voidpf
|
local voidpf
|
||||||
zcalloc ( voidpf opaque,
|
zcalloc ( voidpf opaque,
|
||||||
|
@ -138,7 +140,7 @@
|
||||||
ft_gzip_free( (FT_Memory)opaque, ptr );
|
ft_gzip_free( (FT_Memory)opaque, ptr );
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif /* !SYSTEM_ZLIB */
|
#endif /* !SYSTEM_ZLIB && !USE_ZLIB_ZCALLOC */
|
||||||
|
|
||||||
|
|
||||||
/***************************************************************************/
|
/***************************************************************************/
|
||||||
|
|
|
@ -49,7 +49,7 @@ void zmemzero(dest, len)
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined( MSDOS ) && defined( __TURBOC__ )
|
#if defined( MSDOS ) && defined( __TURBOC__ ) && !defined( MY_ZCALLOC )
|
||||||
#if (defined( __BORLANDC__) || !defined(SMALL_MEDIUM)) && !defined(__32BIT__)
|
#if (defined( __BORLANDC__) || !defined(SMALL_MEDIUM)) && !defined(__32BIT__)
|
||||||
/* Small and medium model in Turbo C are for now limited to near allocation
|
/* Small and medium model in Turbo C are for now limited to near allocation
|
||||||
* with reduced MAX_WBITS and MAX_MEM_LEVEL
|
* with reduced MAX_WBITS and MAX_MEM_LEVEL
|
||||||
|
@ -129,7 +129,7 @@ void zcfree (voidpf opaque, voidpf ptr)
|
||||||
#endif /* MSDOS && __TURBOC__ */
|
#endif /* MSDOS && __TURBOC__ */
|
||||||
|
|
||||||
|
|
||||||
#if defined(M_I86) && !defined(__32BIT__)
|
#if defined(M_I86) && !defined(__32BIT__) && !defined( MY_ZCALLOC )
|
||||||
/* Microsoft C in 16-bit mode */
|
/* Microsoft C in 16-bit mode */
|
||||||
|
|
||||||
# define MY_ZCALLOC
|
# define MY_ZCALLOC
|
||||||
|
|
Loading…
Reference in New Issue