From 38db480acb87152e60e0bf8db3258c31b7079dba Mon Sep 17 00:00:00 2001 From: Manuel Schneider Date: Tue, 3 Jun 2014 14:11:41 +0200 Subject: Remove client list from listenServer. Check maxClients in Mainwindow --- src/server/mainwindow/mainwindow.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/server/mainwindow/mainwindow.cpp') diff --git a/src/server/mainwindow/mainwindow.cpp b/src/server/mainwindow/mainwindow.cpp index 6afa608..d1974ab 100644 --- a/src/server/mainwindow/mainwindow.cpp +++ b/src/server/mainwindow/mainwindow.cpp @@ -812,6 +812,12 @@ void MainWindow::onClientAuthenticated(Client* client) tellClientCurrentSituation(client); return; } + + if (_clientFrames.size() > 50) { + client->deleteLater(); + return; + } + // New one, create ConnectionFrame *cf = createFrame(); // Try to load last known position -- cgit v1.2.3-55-g7522