]> git.sesse.net Git - cubemap/blobdiff - main.cpp
Make Input a bit more generic, to pave the way for UDP.
[cubemap] / main.cpp
index db3be63f2d05a2cbcff27afa620205b97405f524..04d0d3da33b26bd6ae0a44942964d08c230682b2 100644 (file)
--- a/main.cpp
+++ b/main.cpp
@@ -25,6 +25,7 @@
 #include "server.h"
 #include "serverpool.h"
 #include "input.h"
 #include "server.h"
 #include "serverpool.h"
 #include "input.h"
+#include "httpinput.h"
 #include "stats.h"
 #include "state.pb.h"
 
 #include "stats.h"
 #include "state.pb.h"
 
@@ -267,7 +268,7 @@ vector<Input *> create_inputs(const vector<ConfigLine> &config,
                        deserialized_inputs->erase(deserialized_input_it);
                }
                if (input == NULL) {
                        deserialized_inputs->erase(deserialized_input_it);
                }
                if (input == NULL) {
-                       input = new Input(stream_id, src);
+                       input = new HTTPInput(stream_id, src);
                }
                input->run();
                inputs.push_back(input);
                }
                input->run();
                inputs.push_back(input);
@@ -358,7 +359,7 @@ int main(int argc, char **argv)
                for (int i = 0; i < loaded_state.inputs_size(); ++i) {
                        deserialized_inputs.insert(make_pair(
                                loaded_state.inputs(i).stream_id(),
                for (int i = 0; i < loaded_state.inputs_size(); ++i) {
                        deserialized_inputs.insert(make_pair(
                                loaded_state.inputs(i).stream_id(),
-                               new Input(loaded_state.inputs(i))));
+                               new HTTPInput(loaded_state.inputs(i))));
                } 
 
                // Convert the acceptor from older serialized formats.
                } 
 
                // Convert the acceptor from older serialized formats.