Commit 3bb3c0a1 authored by Vivien Kraus's avatar Vivien Kraus
Browse files

Fix a memory leak in the XML test

parent a1e56938
......@@ -48,6 +48,8 @@ unit_test (const char *xml)
abort ();
}
}
tarot_xml_parser_iterator_free (iterator);
tarot_xml_parser_free (parser);
rebuilt = tarot_game_save_to_xml_alloc (game);
if (rebuilt == NULL)
{
......@@ -58,8 +60,8 @@ unit_test (const char *xml)
fprintf (stderr, "%s:%d: %s, size %lu\n", __FILE__, __LINE__, rebuilt, strlen (rebuilt));
abort ();
}
free (rebuilt);
free (game);
tarot_game_free (rebuilt);
tarot_game_free (game);
}
static void
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment