MCPcopy Create free account
hub / github.com/Serial-Studio/Serial-Studio / removeConnection

Method removeConnection

app/src/API/Server.cpp:408–416  ·  view source on GitHub ↗

* @brief Disconnects a client socket from the server. */

Source from the content-addressed store, hash-verified

406 * @brief Disconnects a client socket from the server.
407 */
408void API::Server::removeConnection()
409{
410 auto* socket = qobject_cast<QTcpSocket*>(sender());
411 if (socket) {
412 auto* worker = static_cast<ServerWorker*>(m_worker);
413 QMetaObject::invokeMethod(
414 worker, "removeSocket", Qt::QueuedConnection, Q_ARG(QTcpSocket*, socket));
415 }
416}
417
418/**
419 * @brief Enables or disables the TCP API server.

Callers 1

onQuitMethod · 0.80

Calls 1

senderFunction · 0.85

Tested by

no test coverage detected