* src/truetype/ttxgvar.c (ft_var_load_avar, ft_var_load_gvar): Fix error handling.
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
diff --git a/ChangeLog b/ChangeLog
index 2ba5d12..3e76030 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2004-05-09 George Williams <gww@silcom.com>
+
+ * src/truetype/ttxgvar.c (ft_var_load_avar, ft_var_load_gvar): Fix
+ error handling.
+
2004-05-07 Werner Lemberg <wl@gnu.org>
* src/pfr/pfrobjs.c, src/pfr/pfrobjs.h (pfr_face_init,
diff --git a/src/truetype/ttgxvar.c b/src/truetype/ttgxvar.c
index 09f06b8..820eeb1 100644
--- a/src/truetype/ttgxvar.c
+++ b/src/truetype/ttgxvar.c
@@ -294,7 +294,7 @@
if ( version != 0x00010000L ||
axisCount != (FT_Long)blend->mmvar->num_axis )
- return;
+ goto Exit;
if ( FT_NEW_ARRAY( blend->avar_segment, axisCount ) )
goto Exit;
@@ -1451,9 +1451,6 @@
FT_Stream_SeekSet( stream, here );
}
- FT_FRAME_EXIT();
- goto Exit;
-
Fail3:
FT_FREE( tuple_coords );
FT_FREE( im_start_coords );
@@ -1463,8 +1460,11 @@
FT_FRAME_EXIT();
Fail1:
- FT_FREE( delta_xy );
- *deltas = NULL;
+ if ( error )
+ {
+ FT_FREE( delta_xy );
+ *deltas = NULL;
+ }
Exit:
return error;