X-Git-Url: http://git.maemo.org/git/?p=qtrapids;a=blobdiff_plain;f=src%2Fserver%2Fmain.cpp;h=20d0b9d4b6f584a40fc3db61147499267546a6d7;hp=94272022afe154eb341a9d6106786f903c8edbb7;hb=1d97c0a567b80cf9fc67791669debfe3aa9c4c84;hpb=d27c2db830de9a65d6a419479ee598cbf3697746 diff --git a/src/server/main.cpp b/src/server/main.cpp index 9427202..20d0b9d 100644 --- a/src/server/main.cpp +++ b/src/server/main.cpp @@ -1,3 +1,20 @@ +/*************************************************************************** + * Copyright (C) 2010 by Ixonos Plc * + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; version 2 of the License. * + * * + * This program is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * + * GNU General Public License for more details. * + * * + * You should have received a copy of the GNU General Public License * + * along with this program; if not, write to the * + * Free Software Foundation, Inc., * + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * + ***************************************************************************/ #include //#include "server.h" #include "TorrentSession.hpp" @@ -7,13 +24,14 @@ using qtrapids::settings_weak_ptr; int main(int argc, char *argv[]) { - QCoreApplication::setOrganizationName("Ixonos"); - QCoreApplication::setOrganizationDomain("ixonos.com"); - QCoreApplication::setApplicationName("QtRapids"); - QSettings settings(QCoreApplication::organizationName() - , QCoreApplication::applicationName()); + QCoreApplication::setOrganizationName("Ixonos"); + QCoreApplication::setOrganizationDomain("ixonos.com"); + QCoreApplication::setApplicationName("QtRapids"); + QSettings settings(QCoreApplication::organizationName() + , QCoreApplication::applicationName()); - QCoreApplication app(argc, argv); - TorrentSession server(&app, &settings); - return app.exec(); + QCoreApplication app(argc, argv); + TorrentSession server(&app, &settings); + QObject::connect(&server, SIGNAL(terminate()), &app, SLOT(quit())); + return app.exec(); }