Move the error-handling of failure to initialize the engine from

gnc-engine.c to gnucash-bin.c.  This allows tests that call 
   gnc_engine_init() but fail to find a backend to still pass.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@14232 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
Chris Shoemaker 2006-05-29 04:52:23 +00:00
parent 4a9eea2b4e
commit 2982e18f73
2 changed files with 6 additions and 4 deletions

View File

@ -373,7 +373,11 @@ load_gnucash_modules()
gnc_module_load_optional(modules[i].name, modules[i].version);
else
gnc_module_load(modules[i].name, modules[i].version);
}
}
if (!gnc_engine_is_initialized()) {
g_error("GnuCash engine failed to initialize. Exiting.\n");
exit(0);
}
}
static void

View File

@ -115,9 +115,7 @@ gnc_engine_init(int argc, char ** argv)
/* If this is a required library, stop now! */
if (lib->required)
{
g_message("required library %s not found. Exiting.\n",
lib->lib);
g_assert(FALSE);
g_message("required library %s not found.\n", lib->lib);
}
}
}