From 0cdf930303b4bb453b91374a9657332f7ac31020 Mon Sep 17 00:00:00 2001 From: Keith Smith Date: Wed, 16 Sep 2026 08:28:41 -0600 Subject: [PATCH] Fix connect-time username prompt being unreachable for SSH/RDP validateProfileForConnect() still hard-failed with a blocking QMessageBox for a blank SSH/RDP username, running before requestConnectOptions() ever got a chance to prompt for it inline -- so the connect-time username prompt added for issue #21 was dead code in practice; users just got told to go edit the profile instead. Co-Authored-By: Claude Sonnet 5 --- CMakeLists.txt | 2 +- docs/PROGRESS.md | 9 +++++++++ src/session_tab.cpp | 12 ++++-------- 3 files changed, 14 insertions(+), 9 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 4a2b5cd..5612794 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,6 +1,6 @@ cmake_minimum_required(VERSION 3.21) -project(OrbitHub VERSION 2026.9.16.3 LANGUAGES CXX) +project(OrbitHub VERSION 2026.9.16.4 LANGUAGES CXX) set(CMAKE_CXX_STANDARD 17) set(CMAKE_CXX_STANDARD_REQUIRED ON) diff --git a/docs/PROGRESS.md b/docs/PROGRESS.md index d5421ad..2dabaa3 100644 --- a/docs/PROGRESS.md +++ b/docs/PROGRESS.md @@ -184,6 +184,15 @@ Delivered: through the dialog), so importing any SSH/RDP entry without a username still failed outright until this second check was found and removed too +- A third, independent username check was still live even after the two + above were removed: `SessionTab::validateProfileForConnect()` (run at + the very top of `connectSession()`/`reconnectSession()`, before + `requestConnectOptions()` ever gets a chance to run its async prompt) + had its own hard-fail "SSH/RDP username is required" `QMessageBox`, + so a blank-username profile still couldn't connect at all -- it just + told the user to go edit the profile instead of ever prompting inline. + Removed; connect-time prompting is now the only username gate for + SSH/RDP - Robustness fix: an unrecognized `FramebufferUpdate` rectangle encoding used to abort the connection generically; `kAnnouncedEncodings` is now the single source of truth for what `SetEncodings` announces and what diff --git a/src/session_tab.cpp b/src/session_tab.cpp index a96ed2f..891d7ee 100644 --- a/src/session_tab.cpp +++ b/src/session_tab.cpp @@ -1181,14 +1181,10 @@ bool SessionTab::validateProfileForConnect() return false; } - if ((m_profile.protocol.compare(QStringLiteral("SSH"), Qt::CaseInsensitive) == 0 - || m_profile.protocol.compare(QStringLiteral("RDP"), Qt::CaseInsensitive) == 0) - && m_profile.username.trimmed().isEmpty()) { - QMessageBox::warning(this, - QStringLiteral("Connect"), - QStringLiteral("%1 username is required.").arg(m_profile.protocol)); - return false; - } + // SSH/RDP no longer hard-require a username here -- a blank one is + // handled by requestConnectOptions() prompting for it inline at connect + // time (see issue #21). Do not re-add a check here without also + // updating that flow. return true; }