From 9c1785f93378808292db0fae59ef37cfa3c406dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20K=C3=B6hler?= Date: Fri, 28 Dec 2007 21:44:25 +0000 Subject: [PATCH] Fix two memory leaks. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@16756 57a11ea4-9604-0410-9ed3-97b8803252fd --- lib/libqof/qof/qofbackend.c | 1 + lib/libqof/qof/qofquerycore.c | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/libqof/qof/qofbackend.c b/lib/libqof/qof/qofbackend.c index f35d5d7876..d6954e569c 100644 --- a/lib/libqof/qof/qofbackend.c +++ b/lib/libqof/qof/qofbackend.c @@ -393,6 +393,7 @@ qof_load_backend_library (const char *directory, const char* module_name) g_return_val_if_fail(g_module_supported(), FALSE); fullpath = g_module_build_path(directory, module_name); backend = g_module_open(fullpath, G_MODULE_BIND_LAZY); + g_free(fullpath); if (!backend) { g_message ("%s: %s\n", PACKAGE, g_module_error ()); return FALSE; diff --git a/lib/libqof/qof/qofquerycore.c b/lib/libqof/qof/qofquerycore.c index f10ef5beb8..81018db899 100644 --- a/lib/libqof/qof/qofquerycore.c +++ b/lib/libqof/qof/qofquerycore.c @@ -222,9 +222,8 @@ string_free_pdata (QofQueryPredData *pd) if (pdata->is_regex) regfree (&pdata->compiled); - else - g_free (pdata->matchstring); + g_free (pdata->matchstring); g_free (pdata); }