bugfix, more deck list submission code

This commit is contained in:
Max-Wilhelm Bruker 2009-11-17 18:36:30 +01:00
parent fdf921e718
commit 7a07a395f1
10 changed files with 118 additions and 113 deletions

View file

@ -28,13 +28,12 @@ Servatrice::Servatrice(QObject *parent)
: Server(parent)
{
ProtocolItem::initializeHash();
settings = new QSettings("servatrice.ini", QSettings::IniFormat, this);
tcpServer = new QTcpServer(this);
connect(tcpServer, SIGNAL(newConnection()), this, SLOT(newConnection()));
tcpServer->listen(QHostAddress::Any, 4747); // XXX make customizable
tcpServer->listen(QHostAddress::Any, settings->value("server/port", 4747).toInt());
settings = new QSettings("servatrice.ini", QSettings::IniFormat, this);
QString dbType = settings->value("database/type").toString();
if (dbType == "mysql")
openDatabase();