[konsole] [Bug 439555] Memory leak in SSH manager.
Martin Sandsmark
bugzilla_noreply at kde.org
Thu Jul 8 10:08:00 BST 2021
https://bugs.kde.org/show_bug.cgi?id=439555
--- Comment #2 from Martin Sandsmark <martin.sandsmark at kde.org> ---
Just looking at the code, the thing leaked is the QRegularExpressionValidator.
So this I think should be enough, but I haven't had time to test:
diff --git src/plugins/SSHManager/sshmanagerpluginwidget.cpp
src/plugins/SSHManager/sshmanagerpluginwidget.cpp
index bd2f1539..7ba52b64 100644
--- src/plugins/SSHManager/sshmanagerpluginwidget.cpp
+++ src/plugins/SSHManager/sshmanagerpluginwidget.cpp
@@ -51,7 +51,7 @@ d(std::make_unique<SSHManagerTreeWidget::Private>())
QStringLiteral(R"(^[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$)")
);
- const auto* hostnameValidator = new
QRegularExpressionValidator(hostnameRegex);
+ const auto* hostnameValidator = new
QRegularExpressionValidator(hostnameRegex, this);
ui->hostname->setValidator(hostnameValidator);
const auto* portValidator = new QIntValidator(0, 9999);
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the konsole-devel
mailing list