From: Steinar H. Gunderson Date: Sun, 14 Apr 2013 18:10:49 +0000 (+0200) Subject: Do not start the servers until all the deserialized clients have been put back. Fixes... X-Git-Tag: 1.0.0~110 X-Git-Url: https://git.sesse.net/?p=cubemap;a=commitdiff_plain;h=e4637f55fbd4671089b6700fdd17c3110587436f Do not start the servers until all the deserialized clients have been put back. Fixes an assert failure on load, and makes for faster loads. --- diff --git a/main.cpp b/main.cpp index 95a72b8..64cab64 100644 --- a/main.cpp +++ b/main.cpp @@ -303,8 +303,6 @@ start: // Find all streams in the configuration file, and create them. create_streams(config, deserialized_stream_ids, &deserialized_inputs); - servers->run(); - vector acceptors = create_acceptors(config, &deserialized_acceptors); vector inputs = create_inputs(config, &deserialized_inputs); @@ -317,6 +315,8 @@ start: for (int i = 0; i < loaded_state.clients_size(); ++i) { servers->add_client_from_serialized(loaded_state.clients(i)); } + + servers->run(); // Start writing statistics. StatsThread *stats_thread = NULL;