Decouple QofBook creation from QofSession.

So that we don't create two books when loading a session.
Step 1 to not having a dirty book when we think we should have no
book at all.
This commit is contained in:
John Ralls
2018-06-17 16:43:33 -07:00
parent 0a4347bd5e
commit 8ff5af4c19
21 changed files with 146 additions and 145 deletions

View File

@@ -24,12 +24,15 @@
int main()
{
const char* testurl = "sqlite3://" TESTFILE;
char * no_args[1] = { NULL };
QofSession* s = NULL;
qof_log_init();
qof_init();
char * no_args[1] = { NULL };
gnc_engine_init(0, no_args);
QofSession * s = qof_session_new();
s = qof_session_new(NULL);
qof_session_begin(s, testurl, 0, 1, 0);
qof_session_load(s, NULL);
qof_session_save(s, NULL);