ref: f47acf2b5fcd9d6c9dc58809ef8ecf1b1e0b46ad
parent: e85baf4f8e9ba09fd16d31808b6a5d31735b13bf
author: Werner Lemberg <[email protected]>
date: Mon Jan 12 15:11:14 EST 2009
Avoid compiler warnings. * */*: s/do ; while ( 0 )/do { } while ( 0 )/. Reported by Sean McBride <[email protected]>.
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
2009-01-12 Werner Lemberg <[email protected]>
+ Avoid compiler warnings.
+
+ * */*: s/do ; while ( 0 )/do { } while ( 0 )/.
+ Reported by Sean McBride <[email protected]>.
+
+2009-01-12 Werner Lemberg <[email protected]>
+
Fix stdlib dependencies.
Problem reported by Mickey Gabel <[email protected]>.
--- a/include/freetype/internal/ftdebug.h
+++ b/include/freetype/internal/ftdebug.h
@@ -4,7 +4,7 @@
/* */
/* Debugging and logging component (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2004, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2004, 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, */
@@ -92,7 +92,7 @@
#else /* !FT_DEBUG_LEVEL_TRACE */
-#define FT_TRACE( level, varformat ) do ; while ( 0 ) /* nothing */
+#define FT_TRACE( level, varformat ) do { } while ( 0 ) /* nothing */
#endif /* !FT_DEBUG_LEVEL_TRACE */
@@ -178,7 +178,7 @@
#else /* !FT_DEBUG_LEVEL_ERROR */
-#define FT_ERROR( varformat ) do ; while ( 0 ) /* nothing */
+#define FT_ERROR( varformat ) do { } while ( 0 ) /* nothing */
#endif /* !FT_DEBUG_LEVEL_ERROR */
@@ -201,7 +201,7 @@
#else /* !FT_DEBUG_LEVEL_ERROR */
-#define FT_ASSERT( condition ) do ; while ( 0 )
+#define FT_ASSERT( condition ) do { } while ( 0 )
#endif /* !FT_DEBUG_LEVEL_ERROR */
--- a/src/autofit/aftypes.h
+++ b/src/autofit/aftypes.h
@@ -69,7 +69,7 @@
#else /* !AF_DEBUG */
-#define AF_LOG( x ) do ; while ( 0 ) /* nothing */
+#define AF_LOG( x ) do { } while ( 0 ) /* nothing */
#endif /* !AF_DEBUG */
--- a/src/gxvalid/gxvcommn.h
+++ b/src/gxvalid/gxvcommn.h
@@ -275,11 +275,11 @@
#else /* !FT_DEBUG_LEVEL_TRACE */
-#define GXV_INIT do ; while ( 0 )
-#define GXV_NAME_ENTER( name ) do ; while ( 0 )
-#define GXV_EXIT do ; while ( 0 )
+#define GXV_INIT do { } while ( 0 )
+#define GXV_NAME_ENTER( name ) do { } while ( 0 )
+#define GXV_EXIT do { } while ( 0 )
-#define GXV_TRACE( s ) do ; while ( 0 )
+#define GXV_TRACE( s ) do { } while ( 0 )
#endif /* !FT_DEBUG_LEVEL_TRACE */
--- a/src/otvalid/otvcommn.h
+++ b/src/otvalid/otvcommn.h
@@ -192,12 +192,12 @@
valid->func[2] = OTV_FUNC( z ); \
FT_END_STMNT
-#define OTV_INIT do ; while ( 0 )
-#define OTV_ENTER do ; while ( 0 )
-#define OTV_NAME_ENTER( name ) do ; while ( 0 )
-#define OTV_EXIT do ; while ( 0 )
+#define OTV_INIT do { } while ( 0 )
+#define OTV_ENTER do { } while ( 0 )
+#define OTV_NAME_ENTER( name ) do { } while ( 0 )
+#define OTV_EXIT do { } while ( 0 )
-#define OTV_TRACE( s ) do ; while ( 0 )
+#define OTV_TRACE( s ) do { } while ( 0 )
#endif /* !FT_DEBUG_LEVEL_TRACE */
--- a/src/raster/ftraster.c
+++ b/src/raster/ftraster.c
@@ -181,13 +181,13 @@
/* Disable the tracing mechanism for simplicity -- developers can */
/* activate it easily by redefining these two macros. */
#ifndef FT_ERROR
-#define FT_ERROR( x ) do ; while ( 0 ) /* nothing */
+#define FT_ERROR( x ) do { } while ( 0 ) /* nothing */
#endif
#ifndef FT_TRACE
-#define FT_TRACE( x ) do ; while ( 0 ) /* nothing */
-#define FT_TRACE1( x ) do ; while ( 0 ) /* nothing */
-#define FT_TRACE6( x ) do ; while ( 0 ) /* nothing */
+#define FT_TRACE( x ) do { } while ( 0 ) /* nothing */
+#define FT_TRACE1( x ) do { } while ( 0 ) /* nothing */
+#define FT_TRACE6( x ) do { } while ( 0 ) /* nothing */
#endif
#define Raster_Err_None 0
@@ -370,7 +370,7 @@
#define RAS_VARS /* void */
#define RAS_VAR /* void */
-#define FT_UNUSED_RASTER do ; while ( 0 )
+#define FT_UNUSED_RASTER do { } while ( 0 )
#else /* FT_STATIC_RASTER */
--- a/src/smooth/ftgrays.c
+++ b/src/smooth/ftgrays.c
@@ -163,9 +163,9 @@
#else /* !FT_DEBUG_LEVEL_TRACE */
-#define FT_TRACE5( x ) do ; while ( 0 ) /* nothing */
-#define FT_TRACE7( x ) do ; while ( 0 ) /* nothing */
-#define FT_ERROR( x ) do ; while ( 0 ) /* nothing */
+#define FT_TRACE5( x ) do { } while ( 0 ) /* nothing */
+#define FT_TRACE7( x ) do { } while ( 0 ) /* nothing */
+#define FT_ERROR( x ) do { } while ( 0 ) /* nothing */
#endif /* !FT_DEBUG_LEVEL_TRACE */