From dacb6a0671bd8ee1de8e468ffd5ad5744649fa86 Mon Sep 17 00:00:00 2001 From: Dave Peticolas Date: Fri, 28 Sep 2001 10:08:45 +0000 Subject: [PATCH] Remove book paths on gnc_book_end. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@5438 57a11ea4-9604-0410-9ed3-97b8803252fd --- src/backend/postgres/test/test-db.c | 5 ++++- src/engine/gnc-book.c | 9 +++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/src/backend/postgres/test/test-db.c b/src/backend/postgres/test/test-db.c index a791289a71..883de23f7b 100644 --- a/src/backend/postgres/test/test-db.c +++ b/src/backend/postgres/test/test-db.c @@ -37,6 +37,9 @@ test_book (GNCBook *book) if (!do_test (io_err == ERR_BACKEND_NO_ERR, "Ending test-file-1")) return; + if (!do_test (gnc_book_get_url (book) == NULL, "book url not NULL")) + return; + filename = g_strdup ("postgres://localhost:7777/gnc_test?mode=single-file"); gnc_book_begin (book, filename, FALSE, TRUE); g_free (filename); @@ -77,7 +80,7 @@ guile_main (int argc, char **argv) int main (int argc, char ** argv) { - /* getchar (); */ + getchar (); gh_enter (argc, argv, guile_main); diff --git a/src/engine/gnc-book.c b/src/engine/gnc-book.c index d6ecaaec87..84180904b7 100644 --- a/src/engine/gnc-book.c +++ b/src/engine/gnc-book.c @@ -686,6 +686,15 @@ gnc_book_end (GNCBook *book) gnc_book_clear_error (book); + g_free (book->fullpath); + book->fullpath = NULL; + + g_free (book->logpath); + book->logpath = NULL; + + g_free (book->book_id); + book->book_id = NULL; + LEAVE(" "); }