From b839a2cb123028bff6f6d52229bf9b0993762495 Mon Sep 17 00:00:00 2001 From: schroedtert <t.schroedter@fz-juelich.de> Date: Sun, 7 Feb 2021 12:11:35 +0100 Subject: [PATCH] Add error message box and cancel import when not supported trc version found in trc file Signed-off-by: schroedtert <t.schroedter@fz-juelich.de> --- src/petrack.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/petrack.cpp b/src/petrack.cpp index d0a4c74a5..133e0cd9d 100644 --- a/src/petrack.cpp +++ b/src/petrack.cpp @@ -2594,7 +2594,8 @@ void Petrack::importTracker(QString dest) //default = "" else { debout << "Error: wrong header while reading TRC file." << endl; - sz = 0; + QMessageBox::critical(this, tr("PeTrack"), tr("Could not import tracker:\nNot supported trc version in file: %1.").arg(dest)); + return; } in >> sz; } -- GitLab