X-Git-Url: https://git.llucax.com/z.facultad/75.42/plaqui.git/blobdiff_plain/989d0da7e93d155dde399bf3047ab6b4af550bb6..dd5a5045d5549015b6500726098cb43d1e1c614c:/Server/src/server.cpp?ds=sidebyside diff --git a/Server/src/server.cpp b/Server/src/server.cpp index 8704d69..837295f 100644 --- a/Server/src/server.cpp +++ b/Server/src/server.cpp @@ -53,18 +53,19 @@ Server::~Server(void) { } } -Server::Server(int port): TCPServer(port) { +Server::Server(const string& plant_filename, const Connection::Port& port): + TCPServer(port) { #ifdef DEBUG cerr << __FILE__ << ": port = " << port << endl; #endif // DEBUG // FIXME Glib::Mutex::Lock lock(plants_mutex); - plants["prueba"] = new Plant("prueba.xml"); - plants["prueba"]->signal_finished().connect( + plants["default"] = new Plant(plant_filename); + plants["default"]->signal_finished().connect( SigC::bind( SigC::slot_class(*this, &Server::on_plant_finished), - "prueba")); - plants["prueba"]->run(); + "default")); + plants["default"]->run(); } Connection* Server::new_connection(