QVncScreen: fix crash on disconnect client did not request cursor
Change-Id: I758c79d87bd239b6fde9bae4e97c5b31450fa813 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> (cherry picked from commit c4b172b7f0158fccf6d0ac1a72081d0749410b1b) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
parent
47fed5b007
commit
22b82fbb96
@ -139,6 +139,9 @@ void QVncScreen::enableClientCursor(QVncClient *client)
|
|||||||
void QVncScreen::disableClientCursor(QVncClient *client)
|
void QVncScreen::disableClientCursor(QVncClient *client)
|
||||||
{
|
{
|
||||||
#if QT_CONFIG(cursor)
|
#if QT_CONFIG(cursor)
|
||||||
|
if (!clientCursor)
|
||||||
|
return;
|
||||||
|
|
||||||
uint clientCount = clientCursor->removeClient(client);
|
uint clientCount = clientCursor->removeClient(client);
|
||||||
if (clientCount == 0) {
|
if (clientCount == 0) {
|
||||||
delete clientCursor;
|
delete clientCursor;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user