> Not sure if it's caused by the merge, but it gives a warning with gcc 7.2.0: > > --- > In file included from > /home/nsivov/devel/freetype/freetype2/src/psaux/psaux.c:35:0: > /home/nsivov/devel/freetype/freetype2/src/psaux/pshints.c: In function > ‘cf2_hintmap_dump’: > /home/nsivov/devel/freetype/freetype2/src/psaux/pshints.c:312:17: warning: > unused variable ‘hint’ [-Wunused-variable] > CF2_Hint hint = &hintmap->edge[i]; > ^~~~ > ---
Yes, it is caused by the tracing procedure I added to debug the initial hintmap issue. All this does is use FT_TRACE to print out some tables, so if debug mode isn't turned on, the `hint' variable's not being used. The following patch should fix it: >From ca8de3f50731167a8a096a5a8afb7b171fa3f640 Mon Sep 17 00:00:00 2001 From: Ewald Hew <[email protected]> Date: Tue, 26 Sep 2017 00:16:26 +0800 Subject: [PATCH] Fix compiler warning. --- src/psaux/pshints.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/psaux/pshints.c b/src/psaux/pshints.c index cf40bc0..c8ad4e0 100644 --- a/src/psaux/pshints.c +++ b/src/psaux/pshints.c @@ -302,6 +302,7 @@ static void cf2_hintmap_dump( CF2_HintMap hintmap ) { +#ifdef FT_DEBUG_LEVEL_TRACE CF2_UInt i; @@ -321,6 +322,9 @@ ( cf2_hint_isLocked( hint ) ? "L" : ""), ( cf2_hint_isSynthetic( hint ) ? "S" : "" ) )); } +#else + FT_UNUSED( hintmap ); +#endif } -- 2.1.4 Ewald
From ca8de3f50731167a8a096a5a8afb7b171fa3f640 Mon Sep 17 00:00:00 2001 From: Ewald Hew <[email protected]> Date: Tue, 26 Sep 2017 00:16:26 +0800 Subject: [PATCH] Fix compiler warning. --- src/psaux/pshints.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/psaux/pshints.c b/src/psaux/pshints.c index cf40bc0..c8ad4e0 100644 --- a/src/psaux/pshints.c +++ b/src/psaux/pshints.c @@ -302,6 +302,7 @@ static void cf2_hintmap_dump( CF2_HintMap hintmap ) { +#ifdef FT_DEBUG_LEVEL_TRACE CF2_UInt i; @@ -321,6 +322,9 @@ ( cf2_hint_isLocked( hint ) ? "L" : ""), ( cf2_hint_isSynthetic( hint ) ? "S" : "" ) )); } +#else + FT_UNUSED( hintmap ); +#endif } -- 2.1.4
_______________________________________________ Freetype-devel mailing list [email protected] https://lists.nongnu.org/mailman/listinfo/freetype-devel
