aboutsummaryrefslogtreecommitdiffstats
path: root/src/init_def.cpp
diff options
context:
space:
mode:
authorlloyd <[email protected]>2007-10-13 20:40:49 +0000
committerlloyd <[email protected]>2007-10-13 20:40:49 +0000
commit83784f32b65b822636355eafa0ba744456cdc753 (patch)
tree4e0cd71c49ddc1454dae15284802bbe8ea52c083 /src/init_def.cpp
parente0fe7b1a473dd862e41a662d4bb9edab381370cf (diff)
The last checkin did not work; the Library_State constructor called code1.7.2
that called global_state(), which cased an infinite recursion. Make creating a Library_State a two-phase operation, first an empty constructor (just sets all pointers to NULL), then an initializer that sets up everything needed to start up the library.
Diffstat (limited to 'src/init_def.cpp')
-rw-r--r--src/init_def.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/init_def.cpp b/src/init_def.cpp
index 50365b3d6..abfbe646e 100644
--- a/src/init_def.cpp
+++ b/src/init_def.cpp
@@ -18,7 +18,9 @@ void LibraryInitializer::initialize(const InitializerOptions& args,
{
try
{
- set_global_state(new Library_State(args, modules));
+ set_global_state(new Library_State);
+
+ global_state().initialize(args, modules);
if(args.fips_mode() || args.self_test())
{