From 80c253f9e88e2fd94deaaa692d776314b2eaa504 Mon Sep 17 00:00:00 2001 From: Werner Lemberg Date: Thu, 19 Mar 2009 08:05:06 +0100 Subject: [PATCH] Remove unused WinCE code. * builds/win32/ftdebug.c: Remove code guarded with `_WIN32_WCE'. Since WinCE is handled separately this is no longer needed. --- ChangeLog | 7 +++++++ builds/win32/ftdebug.c | 40 +++------------------------------------- 2 files changed, 10 insertions(+), 37 deletions(-) diff --git a/ChangeLog b/ChangeLog index 40385cbcd..731581761 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2009-03-19 Werner Lemberg + + Remove unused WinCE code. + + * builds/win32/ftdebug.c: Remove code guarded with `_WIN32_WCE'. + Since WinCE is handled separately this is no longer needed. + 2009-03-16 Werner Lemberg docmaker: Don't ignore single-line code blocks. diff --git a/builds/win32/ftdebug.c b/builds/win32/ftdebug.c index 8f7a9ab07..d1ca15ac9 100644 --- a/builds/win32/ftdebug.c +++ b/builds/win32/ftdebug.c @@ -4,7 +4,7 @@ /* */ /* Debugging and logging component for Win32 (body). */ /* */ -/* Copyright 1996-2001, 2002, 2005, 2008 by */ +/* Copyright 1996-2001, 2002, 2005, 2008, 2009 by */ /* David Turner, Robert Wilhelm, and Werner Lemberg. */ /* */ /* This file is part of the FreeType project, and may only be used, */ @@ -55,29 +55,6 @@ #include -#ifdef _WIN32_WCE - - void - OutputDebugStringEx( const char* str ) - { - static WCHAR buf[8192]; - - - int sz = MultiByteToWideChar( CP_ACP, 0, str, -1, buf, - sizeof ( buf ) / sizeof ( *buf ) ); - if ( !sz ) - lstrcpyW( buf, L"OutputDebugStringEx: MultiByteToWideChar failed" ); - - OutputDebugStringW( buf ); - } - -#else - -#define OutputDebugStringEx OutputDebugStringA - -#endif - - FT_BASE_DEF( void ) FT_Message( const char* fmt, ... ) { @@ -89,7 +66,7 @@ vprintf( fmt, ap ); /* send the string to the debugger as well */ vsprintf( buf, fmt, ap ); - OutputDebugStringEx( buf ); + OutputDebugStringA( buf ); va_end( ap ); } @@ -103,7 +80,7 @@ va_start( ap, fmt ); vsprintf( buf, fmt, ap ); - OutputDebugStringEx( buf ); + OutputDebugStringA( buf ); va_end( ap ); exit( EXIT_FAILURE ); @@ -149,19 +126,8 @@ FT_BASE_DEF( void ) ft_debug_init( void ) { -#ifdef _WIN32_WCE - - /* Windows Mobile doesn't have environment API: */ - /* GetEnvironmentStrings, GetEnvironmentVariable, getenv. */ - /* */ - /* FIXME!!! How to set debug mode? */ - const char* ft2_debug = 0; - -#else - const char* ft2_debug = getenv( "FT2_DEBUG" ); -#endif if ( ft2_debug ) {