From 3f4a60575c69d5970ea3185b768f083bfd168518 Mon Sep 17 00:00:00 2001 From: Steve Frécinaux Date: Tue, 3 Aug 2010 23:39:58 +0200 Subject: Do not leak typelibs with wrong header info. Previously the typelibs that were loaded but whose header information weren't right were just leaked. https://bugzilla.gnome.org/show_bug.cgi?id=625672 --- girepository/girepository.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'girepository') diff --git a/girepository/girepository.c b/girepository/girepository.c index 7c2e2b5..50bcfbd 100644 --- a/girepository/girepository.c +++ b/girepository/girepository.c @@ -1280,6 +1280,7 @@ require_internal (GIRepository *repository, "Typelib file %s for namespace '%s' contains " "namespace '%s' which doesn't match the file name", path, namespace, typelib_namespace); + g_typelib_free (typelib); goto out; } if (version != NULL && strcmp (typelib_version, version) != 0) @@ -1289,6 +1290,7 @@ require_internal (GIRepository *repository, "Typelib file %s for namespace '%s' contains " "version '%s' which doesn't match the expected version '%s'", path, namespace, typelib_version, version); + g_typelib_free (typelib); goto out; } -- cgit v1.2.3