From: Soeren Apel Date: Fri, 28 Aug 2015 06:35:56 +0000 (+0200) Subject: Fix #592 completely by showing the actual error message X-Git-Tag: pulseview-0.3.0~129 X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=accd9c0506657c2444caef9aa3aa5de71a94b60a;p=pulseview.git Fix #592 completely by showing the actual error message Before, the supplied infoMessage was ignored (unnamed parameter) and instead the local variable infoMessage was used, which was empty. For this reason, the cause of the error never showed. --- diff --git a/pv/mainwindow.cpp b/pv/mainwindow.cpp index d7b1aa44..8b32046a 100644 --- a/pv/mainwindow.cpp +++ b/pv/mainwindow.cpp @@ -623,7 +623,6 @@ void MainWindow::load_file(QString file_name, { const QString errorMessage( QString("Failed to load file %1").arg(file_name)); - const QString infoMessage; try { if (format) @@ -646,7 +645,7 @@ void MainWindow::load_file(QString file_name, update_device_list(); - session_.start_capture([&, errorMessage, infoMessage](QString) { + session_.start_capture([&, errorMessage](QString infoMessage) { session_error(errorMessage, infoMessage); }); }