* src/truetype/ttgload.c, src/truetype/ttxgvar.c: removing compiler warnings
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155
diff --git a/ChangeLog b/ChangeLog
index df83950..7d50f0c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2004-06-24 David Turner <david@freetype.org>
+
+ * src/truetype/ttgload.c, src/truetype/ttxgvar.c: removing
+ compiler warnings
+
2004-06-23 Werner Lemberg <wl@gnu.org>
* include/freetype/internal/ftmemory.h [FT_DEBUG_MEMORY]: Declare
diff --git a/src/truetype/ttgload.c b/src/truetype/ttgload.c
index 9fc2d03..2d00bf1 100644
--- a/src/truetype/ttgload.c
+++ b/src/truetype/ttgload.c
@@ -1050,10 +1050,9 @@
FT_Memory memory = loader->face->memory;
- if ( (error = TT_Vary_Get_Glyph_Deltas( (TT_Face)(loader->face),
- glyph_index,
- &deltas,
- 4 ) ) )
+ error = TT_Vary_Get_Glyph_Delts( (TT_Face)(loader->face),
+ glyph_index, &deltas, 4 );
+ if ( error )
goto Exit;
loader->pp1.x += deltas[0].x; loader->pp1.y += deltas[0].y;
@@ -1201,7 +1200,7 @@
face,
glyph_index,
&deltas,
- gloader->current.num_subglyphs + 4 ) ) )
+ gloader->current.num_subglyphs + 4 )) != 0 )
goto Exit;
/* Note: No subglyph reallocation here, our pointers are stable. */
diff --git a/src/truetype/ttgxvar.c b/src/truetype/ttgxvar.c
index e48bb50..38fbde1 100644
--- a/src/truetype/ttgxvar.c
+++ b/src/truetype/ttgxvar.c
@@ -284,8 +284,9 @@
blend->avar_checked = TRUE;
- if ( ( error = face->goto_table( face, TTAG_avar, stream, &table_len ) ) )
+ if ( (error = face->goto_table( face, TTAG_avar, stream, &table_len )) != 0 )
return;
+
if ( FT_FRAME_ENTER( table_len ) )
return;
@@ -387,7 +388,7 @@
FT_FRAME_END
};
- if ( ( error = face->goto_table( face, TTAG_gvar, stream, &table_len ) ) )
+ if ( (error = face->goto_table( face, TTAG_gvar, stream, &table_len )) != 0 )
goto Exit;
gvar_start = FT_STREAM_POS( );
@@ -398,8 +399,8 @@
blend->gv_glyphcnt = gvar_head.glyphCount;
offsetToData = gvar_start + gvar_head.offsetToData;
- if ( gvar_head.version != 0x00010000L ||
- gvar_head.axisCount != blend->mmvar->num_axis )
+ if ( gvar_head.version != (FT_Long)0x00010000L ||
+ gvar_head.axisCount != (FT_UShort)blend->mmvar->num_axis )
{
error = TT_Err_Invalid_Table;
goto Exit;
@@ -443,7 +444,7 @@
goto Exit;
for ( i = 0; i < blend->tuplecount; ++i )
- for ( j = 0 ; j < gvar_head.axisCount; ++j )
+ for ( j = 0 ; j < (FT_UInt)gvar_head.axisCount; ++j )
blend->tuplecoords[i * gvar_head.axisCount + j] =
FT_GET_SHORT() << 2; /* convert to FT_Fixed */
@@ -653,11 +654,12 @@
if ( face->blend == NULL )
{
/* both `fvar' and `gvar' must be present */
- if ( ( error = face->goto_table( face, TTAG_gvar,
- stream, &table_len ) ) )
+ if ( (error = face->goto_table( face, TTAG_gvar,
+ stream, &table_len )) != 0 )
goto Exit;
- if ( ( error = face->goto_table( face, TTAG_fvar,
- stream, &table_len ) ) )
+
+ if ( (error = face->goto_table( face, TTAG_fvar,
+ stream, &table_len )) != 0 )
goto Exit;
fvar_start = FT_STREAM_POS( );
@@ -665,7 +667,7 @@
if ( FT_STREAM_READ_FIELDS( fvar_fields, &fvar_head ) )
goto Exit;
- if ( fvar_head.version != 0x00010000UL ||
+ if ( fvar_head.version != (FT_Long)0x00010000L ||
fvar_head.countSizePairs != 2 ||
fvar_head.axisSize != 20 ||
fvar_head.instanceSize != 4 + 4 * fvar_head.axisCount ||
@@ -855,7 +857,7 @@
if ( face->blend == NULL )
{
- if ( ( error = TT_Get_MM_Var( face, NULL) ) )
+ if ( (error = TT_Get_MM_Var( face, NULL)) != 0 )
goto Exit;
}
@@ -876,7 +878,7 @@
}
if ( blend->glyphoffsets == NULL )
- if ( ( error = ft_var_load_gvar( face ) ) )
+ if ( (error = ft_var_load_gvar( face )) != 0 )
goto Exit;
if ( blend->normalizedcoords == NULL )
@@ -982,7 +984,7 @@
if ( face->blend == NULL )
{
- if ( ( error = TT_Get_MM_Var( face, NULL ) ) )
+ if ( (error = TT_Get_MM_Var( face, NULL )) != 0 )
goto Exit;
}
@@ -1035,7 +1037,7 @@
av = blend->avar_segment;
for ( i = 0; i < mmvar->num_axis; ++i, ++av )
{
- for ( j = 1; j < av->pairCount; ++j )
+ for ( j = 1; j < (FT_UInt)av->pairCount; ++j )
if ( normalized[i] < av->correspondence[j].fromCoord )
{
normalized[i] =
@@ -1319,7 +1321,7 @@
return TT_Err_Invalid_Argument;
/* to be freed by the caller */
- if ( ( error = FT_NEW_ARRAY( delta_xy, n_points ) ) )
+ if ( (error = FT_NEW_ARRAY( delta_xy, n_points )) != 0 )
goto Exit;
*deltas = delta_xy;