diff options
author | Daniel Silverstone <dsilvers@digital-scurf.org> | 2012-11-03 18:03:23 +0000 |
---|---|---|
committer | Daniel Silverstone <dsilvers@digital-scurf.org> | 2012-11-03 18:03:23 +0000 |
commit | 657a6b8cb36918ea57fe8152aa3cc90528f15c58 (patch) | |
tree | e22e34801ab444d7037eefd1c956ff9c46709350 | |
parent | 59568396572ae0147f6741951c88c9ccc05cee80 (diff) | |
download | libsvgtiny-657a6b8cb36918ea57fe8152aa3cc90528f15c58.tar.gz |
Clean up properly
-rw-r--r-- | src/svgtiny.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/svgtiny.c b/src/svgtiny.c index 18884a1..0dd5028 100644 --- a/src/svgtiny.c +++ b/src/svgtiny.c @@ -205,10 +205,18 @@ svgtiny_code svgtiny_parse(struct svgtiny_diagram *diagram, dom_node_unref(document); cleanup: + if (state.gradient_x1 != NULL) + dom_string_unref(state.gradient_x1); + if (state.gradient_x2 != NULL) + dom_string_unref(state.gradient_x2); + if (state.gradient_y1 != NULL) + dom_string_unref(state.gradient_y1); + if (state.gradient_y2 != NULL) + dom_string_unref(state.gradient_y2); #define SVGTINY_STRING_ACTION2(s,n) \ if (state.interned_##s != NULL) \ dom_string_unref(state.interned_##s); -//#include "svgtiny_strings.h" +#include "svgtiny_strings.h" #undef SVGTINY_STRING_ACTION2 return code; } |