Remove book paths on gnc_book_end.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@5438 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
Dave Peticolas 2001-09-28 10:08:45 +00:00
parent 904b2c2acb
commit dacb6a0671
2 changed files with 13 additions and 1 deletions

View File

@ -37,6 +37,9 @@ test_book (GNCBook *book)
if (!do_test (io_err == ERR_BACKEND_NO_ERR, "Ending test-file-1")) if (!do_test (io_err == ERR_BACKEND_NO_ERR, "Ending test-file-1"))
return; 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"); filename = g_strdup ("postgres://localhost:7777/gnc_test?mode=single-file");
gnc_book_begin (book, filename, FALSE, TRUE); gnc_book_begin (book, filename, FALSE, TRUE);
g_free (filename); g_free (filename);
@ -77,7 +80,7 @@ guile_main (int argc, char **argv)
int int
main (int argc, char ** argv) main (int argc, char ** argv)
{ {
/* getchar (); */ getchar ();
gh_enter (argc, argv, guile_main); gh_enter (argc, argv, guile_main);

View File

@ -686,6 +686,15 @@ gnc_book_end (GNCBook *book)
gnc_book_clear_error (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(" "); LEAVE(" ");
} }