From 2bbcd1010aa7f1957ad76b2d370ed15a9c6b7e64 Mon Sep 17 00:00:00 2001 From: Uwe Risse Date: Wed, 7 Dec 2022 00:23:10 +0100 Subject: [PATCH] Prevent a crash when clicking on a message without word 3 in Fieldday or FT Roundup mode. --- widgets/mainwindow.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/widgets/mainwindow.cpp b/widgets/mainwindow.cpp index 7af96b87e..1c049b5e1 100644 --- a/widgets/mainwindow.cpp +++ b/widgets/mainwindow.cpp @@ -4589,7 +4589,7 @@ void MainWindow::guiUpdate() if(m_ntx==2 or m_ntx==3) { QStringList t=ui->tx2->text().split(' ', SkipEmptyParts); int n=t.size(); - m_xSent=t.at(n-2) + " " + t.at(n-1); + if (n > 3) m_xSent=t.at(n-2) + " " + t.at(n-1); } } }