forked from minhngoc25a/freetype2
* src/sdf/ftsdf.c (split_sdf_shape): Memory leak.
* src/sdf/ftsdf.c (split_sdf_shape): Memory leak. After recursion the edges variable becomes `NULL' so reassign it to deallocate the list completely.
This commit is contained in:
parent
470d02aa60
commit
90abe41ead
|
@ -1,3 +1,9 @@
|
||||||
|
2020-07-08 Anuj Verma <anujv@iitbhilai.ac.in>
|
||||||
|
|
||||||
|
* src/sdf/ftsdf.c (split_sdf_shape): Memory leak.
|
||||||
|
After recursion the edges variable becomes `NULL'
|
||||||
|
so reassign it to deallocate the list completely.
|
||||||
|
|
||||||
2020-07-08 Anuj Verma <anujv@iitbhilai.ac.in>
|
2020-07-08 Anuj Verma <anujv@iitbhilai.ac.in>
|
||||||
|
|
||||||
[sdf] Added functions to subdivide a conic curve.
|
[sdf] Added functions to subdivide a conic curve.
|
||||||
|
|
|
@ -824,6 +824,8 @@
|
||||||
edges.head = edges.head->next;
|
edges.head = edges.head->next;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
edges = ((SDF_Contour*)contours.head->data)->edges;
|
||||||
|
|
||||||
/* Deallocate the previous list of edges and */
|
/* Deallocate the previous list of edges and */
|
||||||
/* assign the newly created list to the contour. */
|
/* assign the newly created list to the contour. */
|
||||||
FT_List_Finalize( &edges, sdf_edge_destructor, memory, NULL );
|
FT_List_Finalize( &edges, sdf_edge_destructor, memory, NULL );
|
||||||
|
@ -2712,6 +2714,8 @@
|
||||||
|
|
||||||
FT_CALL( sdf_outline_decompose( outline, shape ) );
|
FT_CALL( sdf_outline_decompose( outline, shape ) );
|
||||||
|
|
||||||
|
split_sdf_shape( shape );
|
||||||
|
|
||||||
FT_CALL( sdf_generate_bounding_box( shape, sdf_params->spread,
|
FT_CALL( sdf_generate_bounding_box( shape, sdf_params->spread,
|
||||||
sdf_params->root.target ) );
|
sdf_params->root.target ) );
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue